Vesly's ASM / C

GroupAI v2

PhantomSentine’s GroupAI made it so if you attack or are attacked by a unit that is part of a group (using AI4 for groups), it would aggro all of them.

However, this doesn’t stop you from abusing the AI. You could still lure or split up enemies and nothing would aggro until you or the opponent attacked.

Therefore, I’ve hooked AiSetDecision just after FillAiDangerMap is done and coordinates are decided on to see if the Ai will walk somewhere dangerous, and if so, aggro the group. This makes group AI a bit more aggressive and seemingly more coordinated. Previously, one unit from the group would usually charge ahead “Leeroy Jenkins” style while the rest of the party would follow next turn.

You may also want to consider your ai3 settings and whether they have a penalty to avoid dangerous tiles, unlike one of the defaults below:

Zoning ai is also worth a mention here.

Additionally I fixed a small bug in GroupAI: error handling for lack of unit added (it had a very miniscule chance of game crashes etc.)

7 Likes