- Joined
- Jul 3, 2006
- Messages
- 102
How do I go about referencing preplaced units in JASS code?
I know that when using a preplaced unit/item in a GUI trigger, WE automatically creates a gg_ variable for it, which can be used to reference this unit. But what if there are no GUI triggers? The only place where this unit can be set to a variable is when it is created:
And since this code is generated and overwritten by WE every time the map saves, it cannot be used to store this into another variable!?
I know that when using a preplaced unit/item in a GUI trigger, WE automatically creates a gg_ variable for it, which can be used to reference this unit. But what if there are no GUI triggers? The only place where this unit can be set to a variable is when it is created:
JASS:
set u = CreateUnit(p , 'U007' , - 1708.6 , - 1267.4 , 277.550)
And since this code is generated and overwritten by WE every time the map saves, it cannot be used to store this into another variable!?
Last edited:

