I am trying to check if a player owns all units in unit group, but first. here is my trigger that sets country regions and adds the bases in a country region to a unit group (lets call the unit group country group)
now i need a trigger that would run every 60 seconds and it will check if a player owns all bases in a country group
but i cant figure out how to check it via conditions
any ideas?
-
Set Countries
-
Events
- Map initialization
- Conditions
-
Actions
- Set countryArea1[1] = Region 000 <gen>
- Set countryArea1[2] = Region 001 <gen>
- Set countryArea1[3] = Region 002 <gen>
- Set countryArea1[4] = Region 003 <gen>
- Set countryArea1[5] = Region 004 <gen>
- Set countryArea2[5] = Region 005 <gen>
-
For each (Integer A) from 1 to 5, do (Actions)
-
Loop - Actions
- Unit Group - Add all units of (Units in countryArea1[(Integer A)] matching (((Unit-type of (Matching unit)) Equal to City) or ((Unit-type of (Matching unit)) Equal to Port))) to countryRegions[(Integer A)]
- Unit Group - Add all units of (Units in countryArea2[(Integer A)] matching (((Unit-type of (Matching unit)) Equal to City) or ((Unit-type of (Matching unit)) Equal to Port))) to countryRegions[(Integer A)]
-
Loop - Actions
-
For each (Integer A) from 1 to 5, do (Actions)
-
Loop - Actions
- Set countryCityCount[(Integer A)] = (Number of units in countryRegions[(Integer A)])
-
Loop - Actions
-
Events
but i cant figure out how to check it via conditions
any ideas?