Shadow
TH.net Regular
- Reaction score
- 23
I get an error when I the map is loading I am fairly certain it has somthing to do with this initializer the error occurred after I put in the loop so that it would cycle through all the players
Code:
function InitTrig_Weapon takes nothing returns nothing
local trigger t = CreateTrigger()
local integer i = -1
loop
call TriggerRegisterPlayerUnitEvent(t, Player(i), EVENT_PLAYER_HERO_LEVEL, null)
set i = i + 1
exitwhen i == 11
endloop
call TriggerAddCondition(t,Condition(function Conditions))
endfunction