HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

Multiple Assault Groups?

08-05-2008, 04:58 AM#1
TheDamien
Is it possible to have the effect of multiple assault groups controlled by a single AI? So far I can not see how it is possible. And is there any documentation on the "harass" variables and how they relate to functions like SuicideOnPlayer, AttackMoveKill, etc.

Finally, is there a reasonable way of passing handles between the map script and an AI script? Hell, is there any place where I can find extensive documentation for all this AI scripting stuff?
08-05-2008, 06:34 AM#2
Pyrogasm
The person to ask about AI stuff would be Moyack, as I know he has experience with JASS AI.
08-05-2008, 01:45 PM#3
moyack
Hmmm... it has been a lot of time since I haven't touch the common.ai, but let me check...
Quote:
Originally Posted by TheDamien
Is it possible to have the effect of multiple assault groups controlled by a single AI? So far I can not see how it is possible. And is there any documentation on the "harass" variables and how they relate to functions like SuicideOnPlayer, AttackMoveKill, etc.
The harass array variables are used to store the units type, amount and maximum amount, and this variables are used in the attack loop. Then this info is used when the FormGroup function is called.

Expand FormGroup function in common.ai:

You can avoid these variable and use directly the AddAssault() function if you consider it appropriate. This function is the native which group the units and internally (hardcoded) the functions SuicideOnPlayer, AttackMoveKill, etc, will order to that group to attack.

About how to do 2 separated attack groups.... I haven't found the way, but I know it's possible because AMAI does this strategy.

Quote:
Finally, is there a reasonable way of passing handles between the map script and an AI script? Hell, is there any place where I can find extensive documentation for all this AI scripting stuff?
The only communication possible between triggers and AI (unfortunately it's not possible AI > triggers) is with this:

Collapse JASS:
native CommandAI            takes player num, integer command, integer data returns nothing

I hope it helps you with your needs.
08-06-2008, 12:00 AM#4
TheDamien
Thanks for the help (it is a bit disappointing that AI scripts can't pass information to triggers, though). I will try to fiddle around and get multiple assault groups working.