- Joined
- May 8, 2010
- Messages
- 150
Okay, basically i have a spawn trigger which creates a unit at a point when another unit dies.
When the unit spawns.. it is ment to go towards a point.
But my trigger doesnt work.. and i cant see why it shouldnt.
[trigger=Spawn Wolf]
Events
Unit - A unit Dies
Conditions
(Unit-type of (Triggering unit)) Equal to Timber Wolf
Actions
Unit - Create 1 Timber Wolf for Player 12 (Brown) at (Center of WolfRegions[(Random integer number between 1 and 3)]) facing (Player 1 (Red) start location)
Unit - Change color of (Last created unit) to Black
Unit Group - Add (Last created unit) to Wolf
[/trigger]
[trigger=Wolf Group]
Events
Time - Every 1.00 seconds of game time
Conditions
Actions
Unit Group - Pick every unit in (Units owned by Player 12 (Brown) of type Footman) and do (Unit - Order (Picked unit) to Attack Ground (Random point in Wolf Region <gen>))
Wait 6.00 seconds
Unit - Change ownership of (Picked unit) to Neutral Hostile and Change color
Unit Group - Remove (Picked unit) from Wolf
Custom script: call DestroyGroup(udg_Wolf)
[/trigger]
When the unit spawns.. it is ment to go towards a point.
But my trigger doesnt work.. and i cant see why it shouldnt.
[trigger=Spawn Wolf]
Events
Unit - A unit Dies
Conditions
(Unit-type of (Triggering unit)) Equal to Timber Wolf
Actions
Unit - Create 1 Timber Wolf for Player 12 (Brown) at (Center of WolfRegions[(Random integer number between 1 and 3)]) facing (Player 1 (Red) start location)
Unit - Change color of (Last created unit) to Black
Unit Group - Add (Last created unit) to Wolf
[/trigger]
[trigger=Wolf Group]
Events
Time - Every 1.00 seconds of game time
Conditions
Actions
Unit Group - Pick every unit in (Units owned by Player 12 (Brown) of type Footman) and do (Unit - Order (Picked unit) to Attack Ground (Random point in Wolf Region <gen>))
Wait 6.00 seconds
Unit - Change ownership of (Picked unit) to Neutral Hostile and Change color
Unit Group - Remove (Picked unit) from Wolf
Custom script: call DestroyGroup(udg_Wolf)
[/trigger]