|
好像很少人发DOTA先知的技能……发芽是JASS的,传送是T的。另外,技能我只做了一级的,传送的效果与DOTA的不一样,不是我做不出来DOTA的效果,而是我想换个效果。只供参考……演示图:
【Dota先知全套技能】.w3x
(178 KB, 下载次数: 121)
JASS代码如下:
function Trig_Faya_Conditions takes nothing returns boolean
if ( not ( GetSpellAbilityId() == 'A000' ) ) then //“A000”技能TD
return false
endif
return true
endfunction
function Trig_Faya_Actions takes nothing returns nothing
local destructable array tree
local integer int
set int = 1
loop
exitwhen int > 8
call CreateDestructableLoc( 'VTlt', PolarProjectionBJ(GetUnitLoc(GetSpellTargetUnit()), 180.00, ( I2R(int) * 45.00 )), GetRandomDirectionDeg(), 1, 0 ) //“VTlt”可破坏物ID
set tree[( int - 1 )] = GetLastCreatedDestructable()
set int = int + 1
endloop
call PolledWait( 5.00 )
set int = 1
loop
exitwhen int > 8
call KillDestructable( tree[( int - 1 )] )
set int = int + 1
endloop
call PolledWait( 2.00 )
set int = 1
loop
exitwhen int > 8
call RemoveDestructable( tree[( int - 1 )] )
set int = int + 1
endloop
endfunction
//===========================================================================
function InitTrig_Faya takes nothing returns nothing
set gg_trg_Faya = CreateTrigger( )
call TriggerRegisterAnyUnitEventBJ( gg_trg_Faya, EVENT_PLAYER_UNIT_SPELL_EFFECT )
call TriggerAddCondition( gg_trg_Faya, Condition( function Trig_Faya_Conditions ) )
call TriggerAddAction( gg_trg_Faya, function Trig_Faya_Actions )
endfunction |
评分
-
查看全部评分
|