- Joined
- Aug 2, 2015
- Messages
- 69
Ive been struggling to make the Ice block ability from wow for my hero. (Hero creates an ice block around him self making him imune for a few secs)
Basicly Ive used a the divine shield ability as an base changing the buff to Frost wyrms Freeze effect.
Here's my trigger :
function Trig_IB_Conditions takes nothing returns boolean
if ( not ( UnitHasBuffBJ(gg_unit_H00J_0005, 'B001') == true ) ) then
return false
endif
return true
endfunction
function Trig_IB_Actions takes nothing returns nothing
call DisableTrigger( GetTriggeringTrigger() )
call PauseUnitBJ( true, gg_unit_H00J_0005 )
call TriggerSleepAction( 10.00 )
call PauseUnitBJ( false, gg_unit_H00J_0005 )
call EnableTrigger( GetTriggeringTrigger() )
endfunction
//===========================================================================
function InitTrig_IB takes nothing returns nothing
set gg_trg_IB = CreateTrigger( )
call TriggerRegisterUnitEvent( gg_trg_IB, gg_unit_H00J_0005, EVENT_UNIT_SPELL_FINISH )
call TriggerAddCondition( gg_trg_IB, Condition( function Trig_IB_Conditions ) )
call TriggerAddAction( gg_trg_IB, function Trig_IB_Actions )
endfunction
The result is currently hero has block for 10s and is imune , pause goes off after 10s but block and imune is still there making him able to move for another 15 or 20s. Ive ofcourse set the right numbers within the ability and such.
Wheres the wrong step ?
Basicly Ive used a the divine shield ability as an base changing the buff to Frost wyrms Freeze effect.
Here's my trigger :
function Trig_IB_Conditions takes nothing returns boolean
if ( not ( UnitHasBuffBJ(gg_unit_H00J_0005, 'B001') == true ) ) then
return false
endif
return true
endfunction
function Trig_IB_Actions takes nothing returns nothing
call DisableTrigger( GetTriggeringTrigger() )
call PauseUnitBJ( true, gg_unit_H00J_0005 )
call TriggerSleepAction( 10.00 )
call PauseUnitBJ( false, gg_unit_H00J_0005 )
call EnableTrigger( GetTriggeringTrigger() )
endfunction
//===========================================================================
function InitTrig_IB takes nothing returns nothing
set gg_trg_IB = CreateTrigger( )
call TriggerRegisterUnitEvent( gg_trg_IB, gg_unit_H00J_0005, EVENT_UNIT_SPELL_FINISH )
call TriggerAddCondition( gg_trg_IB, Condition( function Trig_IB_Conditions ) )
call TriggerAddAction( gg_trg_IB, function Trig_IB_Actions )
endfunction
The result is currently hero has block for 10s and is imune , pause goes off after 10s but block and imune is still there making him able to move for another 15 or 20s. Ive ofcourse set the right numbers within the ability and such.
Wheres the wrong step ?