I
Initeor
Guest
Hi guys!
I've been trying to figure this out, but I'm really stuck.
Basically I want 1 unit of the costum unit-type "Redead" to appear in the "Graveyard" region every 15 seconds (with a special effect when it spawns, but that's unrelevant).
The problem is; I want the unit to spawn ONLY when there is less than 3 units of the same unit-type ("Redead") in the region ("Graveyard").
I thought you guys maybe could help me out a bit.
Would appriciate some help, thank you!
I've been trying to figure this out, but I'm really stuck.
Basically I want 1 unit of the costum unit-type "Redead" to appear in the "Graveyard" region every 15 seconds (with a special effect when it spawns, but that's unrelevant).
The problem is; I want the unit to spawn ONLY when there is less than 3 units of the same unit-type ("Redead") in the region ("Graveyard").
I thought you guys maybe could help me out a bit.
Code:
EVENT
Every 15.00 seconds of game time
CONDITIONS
ACTIONS
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- If - Conditions
- (Numbers of units in (Units in Graveyard <gen>)) Greater than 3
- Then - Actions
- Do nothing
- Else - Actions
- Unit - Create 1 redead for Neutral Hostile at (Random point in Graveyard <gen>) facing Deafult building degrees
Would appriciate some help, thank you!