In this map, I have player 11 as a player that periodically spawns and sends hostile units to attack. I do this using an order command for all units owned by player 11 to find the closest unit that is a map object and go to it. I do this because many of the player units are map objects. The problem is that all player units are capturable by the player 11 wave enemy. This means that if they capture an area they will then just stand there because they are being ordered to go to a map object which is the building they just captured.
What is an efficient way (lag is somewhat of a problem in the map) to have player 11 units find hostiles and attack them, moving on after the hostiles are dead and their buildings are captured, rather than using the current system?
Here is the current state of my order command:
http://i.imgur.com/Ir9kNLS.png
In this map, I have player 11 as a player that periodically spawns and sends hostile units to attack. I do this using an order command for all units owned by player 11 to find the closest unit that is a map object and go to it. I do this because many of the player units are map objects. The problem is that all player units are capturable by the player 11 wave enemy. This means that if they capture an area they will then just stand there because they are being ordered to go to a map object which is the building they just captured.
What is an efficient way (lag is somewhat of a problem in the map) to have player 11 units find hostiles and attack them, moving on after the hostiles are dead and their buildings are captured, rather than using the current system?
I believe there's a unit group function called something like units with alliance to player. And you can specify enemy of player 11.
@MaskedImposter: Go
Thank you I was able to make the units do what I want by using that function. I didn't know it existed.