function EB takes handle Ea,string EA returns unit
return GetStoredInteger(w,I2S(e7(Ea)),EA)
return null
endfunction
Before that i have function:
function e7 takes handle h returns integer
return h
return 0
endfunction
I fix it to:
function e7 takes handle h returns integer
return GetHandleId(h)
endfunction
EB function use by:
Spoiler:
function HQ takes nothing returns nothing
local timer t=GetExpiredTimer() local unit Hr=EB(t,"caster")
local unit u
local location l=DL(GetUnitLoc(Hr),GetRandomReal(50.,800.),GetRandomReal(0,360.))
if GetUnitCurrentOrder(Hr)==852600then
set u=CreateUnit(GetOwningPlayer(Hr),'u00F',GetLocationX(l),GetLocationY(l),bj_UNIT_FACING)
call SetUnitPathing(u,false)
call SetUnitAbilityLevelSwapped('A05U',u,GetUnitAbilityLevelSwapped('A05T',Hr))
call IssueTargetOrderById(u,852226,u)
call UnitApplyTimedLife(u,'BTLF',1.)
endif
call RemoveLocation(l)
set t=null
set Hr=null
set l=null
set u=null
endfunction