|
function Sapphiron_Filter takes nothing returns boolean
local timer SrTimer = GetExpiredTimer ()
local unit caster = GetHandleUnit (SrTimer,"caster") //这里就是出错的位置
local group targets = GetHandleGroup (SrTimer,"targets")
local player owner = GetOwningPlayer (caster)
local unit targ = GetFilterUnit ()
if IsUnitInGroup (targ,targets) then
set SrTimer = null
set caster = null
set owner = null
set targ = null
set targets = null
return false
endif
if GetUnitAbilityLevel (targ,Sapphiron_DRawcode()) <= 0 then
if GetWidgetLife (targ) > 0.405 then
if IsUnitEnemy (targ,owner) then
if IsUnitType (targ,UNIT_TYPE_STRUCTURE) == false then
if Sapphiron_Ultimate () then
set SrTimer = null
set caster = null
set targ = null
set targets = null
set owner = null
return true
endif
if IsUnitType (targ,UNIT_TYPE_MAGIC_IMMUNE) == false then
set SrTimer = null
set caster = null
set targ = null
set targets = null
set owner = null
return true
endif
endif
endif
endif
endif
set SrTimer = null
set caster = null
set owner = null
set targ = null
set targets = null
return false
endfunction
那位知道上面出错的原因? |
|