-
-------- FIRST: SAVE THE UNIT'S PROPWINDOW ( DEFAULT ) --------
-
Custom Script: set udg_MY_UNIT_PROPWINDOW[ udg_ID ] = GetUnitPropWindow( udg_YOUR_UNIT )
-
-------- SECOND: SET THE UNIT'S PROPWINDOW TO 0. --------
-
Custom Script: call SetUnitPropWindow( udg_YOUR_UNIT, 0 )
-
-------- THIRD: IF THE SPELL IS FINISH THEN SET THE UNIT'S PROPWINDOW TO THE SAVED ORIGINAL UNIT'S PROPWINDOW. --------
-
Custom Script: call SetUnitPropWindow( udg_YOUR_UNIT, MY_UNIT_PROPWINDOW[ udg_ID ] )
I'll mark the contents with bold letters.
Custom Script:
set udg_MY_UNIT_PROPWINDOW[ udg_ID ] =
GetUnitPropWindow(
udg_YOUR_UNIT )
Custom Script:
call SetUnitPropWindow( udg_YOUR_UNIT,
0 )
Custom Script: call SetUnitPropWindow( udg_YOUR_UNIT, MY_UNIT_PROPWINDOW[ udg_ID ] )
Contents:
1)
Custom Script = the custom script can be found in GUI Function, In this function you can write a single JASS Line or Scripts.
2)
set = set is the keyword for setting a variable in JASS lines or scripts. Remember: JASS are case sensitives.
3)
udg_ = udg_ thingy is for the global variable that created in the Variable Creator in GUI. udg_ is a prefix from global variables in GUI. "udg" stands for
User Defines Global. You must use udg_ if you're setting a global variable in JASS.
4)
MY_UNIT_PROPWINDOW = This is a real variable, this will be the variable for getting or saving the unit's default propwindow angle.
5)
[ udg_ID ] = The MY_UNIT_PROPWINDOW must be a real array variable to pass the data to the another trigger that will make it MUI.
6)
GetUnitPropWindow = this is the function for getting and saving the unit's default propwindow angle. The parameters or function takes is a unit variable:
GetUnitPropWindow( THE_UNIT ).
7)
call = this is the keyword for JASS in calling actions, functions and etc.
that's why we use this.
8)
SetUnitPropWindow = this is the function for setting the unit's propwindow angle. The parameters are: Unit Variable and Real, so we do set the unit's propwindow angle to
0 because it will disable the movement speed.
For making the unit's propwindow to normal then you would set it's propwindow angle to the default saved unit's propwindow.