Descrição:
O herói (Blademaster) gira freneticamente causando danos á todos os inimigos próximos e lançando ondas destrutivas em todas as direções, causando mais danos á todos os inimigos atingidos.
Requisitos:
JNGP v5d (ou superior) + USMWE
Setup:
- Código:
globals
// Main Spell Rawcode
private constant integer SPELL_RAWCODE = 'A000'
// Dummy Spell Rawcode
private constant integer DUMMY_RAWCODE = 'A001'
// Dummy Unit Rawcode
private constant integer DUMMY_UNIT_RAWCODE = 'dumm'
// Spell Duration
private constant real SPELL_DUR = 7.00
endglobals
Script Inteiro:
- Código:
scope CrushTornado initializer ini
globals
// Main Spell Rawcode
private constant integer SPELL_RAWCODE = 'A000'
// Dummy Spell Rawcode
private constant integer DUMMY_RAWCODE = 'A001'
// Dummy Unit Rawcode
private constant integer DUMMY_UNIT_RAWCODE = 'dumm'
// Spell Duration
private constant real SPELL_DUR = 7.00
endglobals
private function ProjectionX takes real realX,real whichDist,real whichAngle returns real
local real x = realX + whichDist * Cos(whichAngle * 3.14159 / 180.)
return x
endfunction
private function ProjectionY takes real realY,real whichDist,real whichAngle returns real
local real y = realY + whichDist * Sin(whichAngle * 3.14159 / 180.)
return y
endfunction
private function spell_config takes nothing returns nothing
local unit u = null
local unit U = null
local player p = null
local integer i = 0
local real r = 0.
local boolean b = false
local timer t = null
if GetSpellAbilityId()==SPELL_RAWCODE then
set u = GetTriggerUnit()
set p = GetOwningPlayer(u)
set i = GetUnitAbilityLevel(u,GetSpellAbilityId())
set t = CreateTimer()
call TimerStart(t,SPELL_DUR,false,null)
loop
if r == 360. and TimerGetRemaining(t)>0. then
set r = 0.
elseif TimerGetRemaining(t)== 0. then
set b = true
call PauseTimer(t)
call DestroyTimer(t)
set t = null
endif
set r = r + 45.
set U = CreateUnit(p,DUMMY_UNIT_RAWCODE,GetUnitX(u),GetUnitY(u),0.)
call UnitApplyTimedLife(U,'BTLF',1.1)
call UnitAddAbility(U,DUMMY_RAWCODE)
call SetUnitAbilityLevel(U,DUMMY_RAWCODE,i)
call IssuePointOrder(U,"carrionswarm",ProjectionX(GetUnitX(u),128.,r),ProjectionY(GetUnitY(u),128.,r))
set U = null
call TriggerSleepAction(.5)
exitwhen b == true
endloop
set p = null
set u = null
endif
endfunction
private function ini takes nothing returns nothing
local trigger t = CreateTrigger()
local integer i = 0
loop
call TriggerRegisterPlayerUnitEvent(t,Player(i),ConvertPlayerUnitEvent(274),null)
set i = i + 1
exitwhen i == 12
endloop
call TriggerAddAction(t,function spell_config)
set t = null
endfunction
endscope
Atenção:
Edite apenas os dados exibidos na seguinte imagem:
- Arquivo ZIP
- Open Source: pode ser aberto no World Edit
- Arquivo upado no MediaFire