BiGyElLoWhAt
New Member
- Reaction score
- 1
If I have a triggered patrol for a group of units, and I use something like this
pick all units in unit group and do multiple actions
Loop
Order picked unit to attack-move to center of region 1
wait 5 s
Order picked unit to attack-move to center of region 2
wait 5 s
Will this cause/encounter problems if I use the picked unit variable in another trigger?
I want the marines to patrol through 5 regions indefinitely (until triggered off later).
Actual code
Patrol Zones
Events
Conditions
Actions
Unit Group - Pick every unit in Marine_Patrol and do (Actions)
Loop - Actions
Unit - Order (Picked unit) to Attack-Move To (Center of Marine Patrol 1 <gen>)
Wait 4.00 seconds
Unit - Order (Picked unit) to Attack-Move To (Center of Marine Patrol 2 <gen>)
Wait 4.00 seconds
Unit - Order (Picked unit) to Attack-Move To (Center of Marine Patrol 3 <gen>)
Wait 4.00 seconds
Unit - Order (Picked unit) to Attack-Move To (Center of Marine Patrol 4 <gen>)
Wait 4.00 seconds
Unit - Order (Picked unit) to Attack-Move To (Center of Marine Patrol 5 <gen>)
Wait 4.00 seconds
This trigger is enabled once the unit group marine_patrol has 3 units in it, and disabled when it has 0. I generate marines when the overall marine group Marines is less than 5 and add them to fill up marine_patrol to 3... blah blah blah...
pick all units in unit group and do multiple actions
Loop
Order picked unit to attack-move to center of region 1
wait 5 s
Order picked unit to attack-move to center of region 2
wait 5 s
Will this cause/encounter problems if I use the picked unit variable in another trigger?
I want the marines to patrol through 5 regions indefinitely (until triggered off later).
Actual code
Patrol Zones
Events
Conditions
Actions
Unit Group - Pick every unit in Marine_Patrol and do (Actions)
Loop - Actions
Unit - Order (Picked unit) to Attack-Move To (Center of Marine Patrol 1 <gen>)
Wait 4.00 seconds
Unit - Order (Picked unit) to Attack-Move To (Center of Marine Patrol 2 <gen>)
Wait 4.00 seconds
Unit - Order (Picked unit) to Attack-Move To (Center of Marine Patrol 3 <gen>)
Wait 4.00 seconds
Unit - Order (Picked unit) to Attack-Move To (Center of Marine Patrol 4 <gen>)
Wait 4.00 seconds
Unit - Order (Picked unit) to Attack-Move To (Center of Marine Patrol 5 <gen>)
Wait 4.00 seconds
This trigger is enabled once the unit group marine_patrol has 3 units in it, and disabled when it has 0. I generate marines when the overall marine group Marines is less than 5 and add them to fill up marine_patrol to 3... blah blah blah...