English version 2.1
Map: Blastoff.mx2
Save: a 9875 ai allied hero attacks luna on path 30.GX1
In this scenario, the yellow (human player), orange and purple players are allies.
AI hero Agar (orange) is near allied hero Luna (yellow).
End the turn.
AI hero Agar attacks Luna.
During the game, it sometimes happens that allied AI heroes attack each other.
This happens when one of the allied heroes is located on the preprogrammed path (the previous turn) of another hero.
Example:
A green hero's pre-programmed path will cause him to capture a sawmill and he will end his movement on that sawmill.
A red hero's pre-programmed path will cause him to capture the same sawmill.
On the next turn, the green hero capture the sawmill and ends his movement on the sawmill.
When the red hero starts moving, he heads towards the sawmill and since the green hero is located on the sawmill, the red hero attacks the green hero despite being his ally.
In the current example, Agar attacks Luna even though it is possible to pass by to reach his destination.
The program should examine the situation before moving the heroes around, to prevent this from happening.
Files: AI hero attacks human ally hero.7z
Files: https://drive.google.com/file/d/1uvNTqhb7PW3HqbRJ2lmN0cIF4p5X3vlH/view?usp=sharing