• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

[Trigger] Please Help

Status
Not open for further replies.
Level 3
Joined
Nov 3, 2017
Messages
34
There is a trigger, whose task - at the end of the timer to zero the variable of the whole type. The timer starts all right, and the trigger to reset the variable does not work.

Code:
function Trig_ResetP1_Actions takes nothing returns nothing
    set udg_tk[1] = 0
    call DestroyTimer(udg_tkk[1])
endfunction

//===========================================================================
function InitTrig_ResetP1 takes nothing returns nothing
    set gg_trg_ResetP1 = CreateTrigger(  )
    call TriggerRegisterTimerExpireEvent(gg_trg_ResetP1, udg_tkk[1])
    call TriggerAddAction( gg_trg_ResetP1, function Trig_ResetP1_Actions )
endfunction
 
Status
Not open for further replies.
Top