HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

Disable AI-script

03-14-2004, 07:27 PM#1
xxxSpikexxx
Simple Problem: I have Neatral hostile units and i want them to use their skills only if I tell them to using triggers ... how to disable AI-Scripts ? :(
03-14-2004, 07:39 PM#2
AIAndy
That is not a problem with an AI script but with the hard coded AI. There is no way to disable that. But what you can do is catch the orders given to these units and if they are not wanted at that point, block them.
03-14-2004, 08:57 PM#3
xxxSpikexxx
the skill should be used on "unit takes damage" but it does when someone comes near as well... how can i block that?
03-16-2004, 11:39 AM#4
AIAndy
A way would be: Have a global boolean variable that you set to true before you issue an order by trigger.
Then create a trigger that runs when the unit is issued an order. Check if that global boolean is true. If it is true, set it to false and do nothing. If it is false, set it to true and give the unit a different order.
03-16-2004, 01:04 PM#5
xxxSpikexxx
thanks a lot but allready found out that giving th unit to computer player fixes my problem ... now they dont use there abilitys if enemys come in range ... I thought this AI scripts would work for Pc players as well but seems like i was wrong ...