Home   Help Search Login Register  

Author Topic: Creating buildings that AI units fire on  (Read 1366 times)

0 Members and 1 Guest are viewing this topic.

Offline Alex de Large

  • Members
  • *
Creating buildings that AI units fire on
« on: 12 Apr 2007, 12:00:55 »
Hi all!

I'm new to this place, and slowly getting the hang of OFP editing. My current project is improving the Zeus CTI mod in combination with WGL 5.12. Work has mainly focussed on improving the AI, but several interface and cosmetic improvements have also been made. There is no released version yet, but maybe that will happen in the future.

The question I've got is about buildings and AI units. In CTI each side typically builds a base and tries to destroy the one build by the opposing force. In the last version of ZSCTI (0.65), AI units do not fire upon base buildings. There are saboteurs that have special scripts to drop bombs inside buildings, but this is not enough. I want to have tanks and aircraft targetting and fireing upon base buildings as well. I'm pretty sure that the reason they don't shoot at them now is that the base buildings are "neutral" (i.e., they show up as white boxes on the radar scope in vehicles). How can I make these base buildings show up as enemy to the AI?

The config file that defines the base buildings seems to set the sides and threat arrays correctly: side = 1 for west, side = 0 for east, threat = {1,1,1} for most buildings. Am I missing something? I've searched the forum and found that some people have problems with the AI wasting ammo on buildings... well that's exactly what I want if they are near the enemy base! :)

Yours,
Alex de Large


Offline Alex de Large

  • Members
  • *
Re: Creating buildings that AI units fire on
« Reply #1 on: 14 Apr 2007, 21:55:54 »
Well, I found the problem. The cost variable for the buildings needs to be set high enough for the AI to engage. Set to 2,000,000 those buildings are toast!  :good:

And, irTarget needs to be true.
« Last Edit: 14 Apr 2007, 22:57:58 by Alex de Large »