- Joined
- Sep 11, 2006
- Messages
- 172
So I've taken a long vacation from working on maps and now I've started a new project that has run into an odd problem.
In one of my scripts I am unable to store a unit in a group after it is created. I have confirmed in game that the created unit is present, but it is not being stored and I have tested this with other triggers and an integer message that counts the number of units in the group I'm looking at.
Here it is. Look near the bottom.
I must be forgetting something.
Edit:I do realize their are leaks. I will address them later. Just trying to pin down this basic script first.
In one of my scripts I am unable to store a unit in a group after it is created. I have confirmed in game that the created unit is present, but it is not being stored and I have tested this with other triggers and an integer message that counts the number of units in the group I'm looking at.
Here it is. Look near the bottom.
-
Rooms
-

Events
-


Unit - A unit Is issued an order targeting an object
-
-

Conditions
-


(Integer((Distance between (Position of (Ordered unit)) and (Position of (Target destructible of issued order))))) Less than or equal to 500
-


And - All (Conditions) are true
-



Conditions
-




Or - Any (Conditions) are true
-





Conditions
-






(Destructible-type of (Target destructible of issued order)) Equal to Gate (Vertical)
-






(Destructible-type of (Target destructible of issued order)) Equal to Gate (Horizontal)
-






(Destructible-type of (Target destructible of issued order)) Equal to Large Gate (Horizontal)
-






(Destructible-type of (Target destructible of issued order)) Equal to Large Gate (Vertical)
-
-
-
-
-
-

Actions
-


Unit - Order (Ordered unit) to Stop
-


Unit - Order (Ordered unit) to Move To (Position of (Target destructible of issued order))
-


Floating Text - Create floating text that reads +1 Turn above (Ordered unit) with Z offset 0.00, using font size 10.00, color (100.00%, 100.00%, 100.00%), and 0.00% transparency
-


Floating Text - Set the velocity of (Last created floating text) to 64.00 towards 90.00 degrees
-


Floating Text - Change (Last created floating text): Disable permanence
-


Floating Text - Change the lifespan of (Last created floating text) to 5.00 seconds
-


Floating Text - Change the fading age of (Last created floating text) to 4.00 seconds
-


Destructible - Open (Target destructible of issued order)
-


Set Turn = (Turn + 1)
-


-------- Region 000 --------
-


If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-



If - Conditions
-




(Target destructible of issued order) Equal to Gate (Vertical) 0048 <gen>
-
-



Then - Actions
-




Unit - Create 1 Spawner for Player 12 (Brown) at ((Center of Region 000 <gen>) offset by (200.00, 0.00)) facing Default building facing degrees
-




Unit Group - Add (Last created unit) to SpawnersUnite
-




Unit - Set Rally-Point for (Last created unit) to (Center of Region 001 <gen>)
-
-



Else - Actions
-
-


-------- Run Waves --------
-


Trigger - Run Turn Wave <gen> (checking conditions)
-
-
I must be forgetting something.
Edit:I do realize their are leaks. I will address them later. Just trying to pin down this basic script first.

