Помогите плз перевести данный код с точек на координаты. Это периодический таймер. Отталкивание юнитов вокруг героя.
Code
function WCKnock takes nothing returns nothing
local timer t = GetExpiredTimer()
local integer id = GetHandleId(t)
local unit u = LoadUnitHandle(udg_Hash, id, 0)
local group g = LoadGroupHandle(udg_Hash, id, 1)
local real dec = LoadReal(udg_Hash, id, 2)
local integer c = LoadInteger(udg_Hash, id, 3)
local integer i = 1
local location p = GetUnitLoc(u)
local location p1
local location p2
local group h = CreateGroup()
local unit un
local real a
loop
set un = FirstOfGroup(g)
exitwhen un == null
call GroupRemoveUnit( g, un )
set p1 = GetUnitLoc(un)
set a = AngleBetweenPoints( p, p1 )
set p2 = PolarProjectionBJ( p1, dec, a )
if ( IsUnitType(un, UNIT_TYPE_GROUND) == true ) then
call SetUnitPositionLoc( un, p2 )
call DestroyEffect( AddSpecialEffectLoc( "Objects\\Spawnmodels\\Undead\\ImpaleTargetDust\\ImpaleTargetDust.mdl", p2 ) )
call DestroyEffect( AddSpecialEffectLoc( "Abilities\\Weapons\\AncientProtectorMissile\\AncientProtectorMissile.mdl", p2 ) )
call RemoveLocation (p1)
call RemoveLocation (p2)
call GroupAddUnit( h, un )
endif
endloop
call RemoveLocation(p)
call DestroyGroup(g)
set dec = dec * 0.94
set c = c + 1
call SaveAgentHandle(udg_Hash, id, 1, h)
call SaveReal(udg_Hash, id, 2, dec)
call SaveInteger(udg_Hash, id, 3, c)
if (c >= 35) then
call PauseTimer(t)
call DestroyTimer(t)
call FlushChildHashtable(udg_Hash, id)
endif
set t = null
set u = null
set un = null
set g = null
set p = null
set p1 = null
set p2 = null
set h = null
endfunction