Page 1 of 1

Making AI Units attack other AI Units If They Are Nearby.

Posted: October 21st, 2009, 6:14 pm
by knightcyan
I am currently having trouble figuring out how to make AI units like footman who walk to a destination i call path a in regions attack the enemie who also walk to path a if they are not standing still.

Re: Making AI Units attack other AI Units If They Are Nearby.

Posted: October 22nd, 2009, 5:11 pm
by knightcyan
what i mean is i have a trigger that tells creeps to move to a certain region for the allys and the enemies and i want them to attack each other if they meet up with each other before or after they reach that destination.

Re: Making AI Units attack other AI Units If They Are Nearby.

Posted: October 22nd, 2009, 9:22 pm
by Syre
Just make the creeps attack-move to the region instead of just move.

Code: Select all

Unit Group - Pick every unit in (Units in Region 000 <gen> owned by Neutral Hostile) and do (Unit - Order (Picked unit) to Attack-Move To (Center of (Playable map area)))


The action your looking for is "Unit - Issue order targeting a point"

Re: Making AI Units attack other AI Units If They Are Nearby.

Posted: October 23rd, 2009, 6:05 am
by [=ryCgg=]
knightcyan wrote:I am currently having trouble figuring out how to make AI units like footman who walk to a destination i call path a in regions attack the enemie who also walk to path a if they are not standing still.

knightcyan wrote:what i mean is i have a trigger that tells creeps to move to a certain region for the allys and the enemies and i want them to attack each other if they meet up with each other before or after they reach that destination.


Don't double post, use the edit button.

kthx.