Array
(
[scriptVersion] => 7
[oeValues] => Array
(
[Ubertip] => A haunted hand with a mind of it's own, it attacks with reckless fervor.
[Art] => ReplaceableTextures\CommandButtons\BTNDoom.blp
[abilList] => Array
(
)
[Name] => Haunted Hand
)
[settings] => Array
(
[balanceTip] => |n|cffFFFF80Specials:|r|n|cffFFFF00+8% |rattackspeed (|cffFFFF00+0.2%|r/lvl)
[goldcost] => 342
[author] => Sunken
[authorDisplay] => |c007EBFF1Sunken|r
[version] => beta v2.0
[rarity] => rare
)
[dmgTable] => Array
(
[0] => Array
(
[id] => MOD_ATTACKSPEED
[base] => 0.08
[add] => 0.002
)
)
[triggers] => Array
(
[0] => Array
(
[name] => On Attack
[code] => local Tower tower = itm.getCarrier()
local timer t
if tower.typ.dmgpt > 0 then
set t = NewTimer()
call SetTimerData(t,tower)
call TimerStart(t, pendingAttacksTimerStep, false, function doIt)
set t = null
else
call attackRandomUnit(tower)
endif
[values] => Array
(
[explain] => This item makes its carrier attack random targets.
[visible] => true
[goldcost] => -50
[name] => Haunted!
[ONATTACK_chance] => 1.0
[ONATTACK_chanceLevelAdd] => 0.0
)
)
[1] => Array
(
[name] => Header
[code] => globals
endglobals
function attackRandomUnit takes Tower tower returns nothing
local Iterate it = Iterate.overUnitsInRangeOfCaster(tower, TARGET_CREEPS, tower.getRange())
local Creep creep = it.nextRandom()
if creep != 0 then
call it.destroy()
call IssueTargetOrder(tower.getUnit(), "attack", creep.getUnit())
endif
endfunction
function doIt takes nothing returns nothing
local timer t = GetExpiredTimer()
call attackRandomUnit(GetTimerData(t))
call ReleaseTimer(t)
set t = null
endfunction
//Do not remove or rename this function!
//Put your initialization tasks here, this function will be called on map init
private function init takes nothing returns nothing
endfunction
[values] => Array
(
[explain] =>
[visible] => false
[goldcost] => 0
[name] =>
)
)
)
[abilities] => Array
(
)
[buffs] => Array
(
)
[units] => Array
(
)
[references] => Array
(
)
)