//TESH.scrollpos=0
//TESH.alwaysfold=0
Name | Type | is_array | initial_value |
//TESH.scrollpos=7
//TESH.alwaysfold=0
library buf initializer initbuffs
globals
integer array Buff //only one=)
endglobals
function buffs takes location l, unit d, integer s returns nothing
local unit b
set b = CreateUnitAtLoc(Player(PLAYER_NEUTRAL_PASSIVE), 'h000', l, 0.00)
call UnitAddAbility(b, Buff[s])
call IssueTargetOrder( b, "bloodlust", d )
call TriggerSleepAction (0.3)//necessary in order to dummy had cast ability
call RemoveUnit(b) //remove dummy
call RemoveLocation(l)
set d = null
set l = null
endfunction
function dispel takes unit u returns nothing //remove all buffs
call UnitRemoveBuffs(u, true, true)
endfunction
function initbuffs takes nothing returns nothing //init all buffs
set Buff[1] = 'A000'
set Buff[2] = 'A001'
set Buff[3] = 'A002'
endfunction
endlibrary