Weirdoze
New Member
- Reaction score
- 6
So, I just started learning JASS today so I have some (probably) very noobish questions
First is, how do i set a new value for a global variable?
And second what is wrong with this
errors in:
if udg_global_HA == 0 then call CustomDefeatBJ( Player(0), "TRIGSTR_005" )
if udg_global_OA == 0 then call CustomDefeatBJ( Player(1), "TRIGSTR_005" )
HA and OA are integers with no array.
Please don't be mad if i ask very noobish questions
First is, how do i set a new value for a global variable?
And second what is wrong with this
JASS:
function Trig_Untitled_Trigger_002_Actions takes nothing returns nothing
if udg_global_HA == 0 then call CustomDefeatBJ( Player(0), "TRIGSTR_005" )
if udg_global_OA == 0 then call CustomDefeatBJ( Player(1), "TRIGSTR_005" )
endfunction
//===========================================================================
function InitTrig_Untitled_Trigger_002 takes nothing returns nothing
set gg_trg_Untitled_Trigger_002 = CreateTrigger( )
call TriggerRegisterAnyUnitEventBJ( gg_trg_Untitled_Trigger_002, EVENT_PLAYER_UNIT_DEATH )
call TriggerAddAction( gg_trg_Untitled_Trigger_002, function Trig_Untitled_Trigger_002_Actions )
endfunction
errors in:
if udg_global_HA == 0 then call CustomDefeatBJ( Player(0), "TRIGSTR_005" )
if udg_global_OA == 0 then call CustomDefeatBJ( Player(1), "TRIGSTR_005" )
HA and OA are integers with no array.
Please don't be mad if i ask very noobish questions