this is the code, mostly its a converted gui
i tried to make it MUI but MPI would also be great, i know it still has leaks, im fixing it,
heres the problem, i cast at 000x00 but i arrive at 0000x0 its like that
i tried to make it MUI but MPI would also be great, i know it still has leaks, im fixing it,
heres the problem, i cast at 000x00 but i arrive at 0000x0 its like that
JASS:
function Trig_Channel_Locals_Conditions takes nothing returns boolean
if ( not ( GetSpellAbilityId() == 039;A001039; ) ) then
return false
endif
return true
endfunction
function Trig_Channel_Locals_Actions takes nothing returns nothing
local unit udg_Skilll_Slice_Unit
local player udg_Skilll_Slice_Player
local location udg_zz_temp_point
local location udg_Skilll_Slice_Point
local real udg_Skilll_Slice_Degrees
local integer udg_Skilll_Slice_Integer
local real udg_Skilll_Slice_Offset
local integer in
set udg_Skilll_Slice_Unit = GetTriggerUnit()
set udg_Skilll_Slice_Player = GetOwningPlayer(GetTriggerUnit())
set udg_zz_temp_point = GetUnitLoc(GetTriggerUnit())
set udg_Skilll_Slice_Point = GetSpellTargetLoc()
set udg_Skilll_Slice_Degrees = AngleBetweenPoints(udg_zz_temp_point, udg_Skilll_Slice_Point)
set udg_Skilll_Slice_Integer = ( R2I(DistanceBetweenPoints(udg_zz_temp_point, udg_Skilll_Slice_Point)) / 100 )
set udg_Skilll_Slice_Offset = ( DistanceBetweenPoints(udg_zz_temp_point, udg_Skilll_Slice_Point) / I2R(udg_Skilll_Slice_Integer) )
set udg_Skilll_Slice_Point = PolarProjectionBJ(udg_zz_temp_point, udg_Skilll_Slice_Offset, udg_Skilll_Slice_Degrees)
call ShowUnitHide( udg_Skilll_Slice_Unit )
set in = 1
loop
exitwhen in > udg_Skilll_Slice_Integer
set udg_Skilll_Slice_Point = PolarProjectionBJ(udg_Skilll_Slice_Point, udg_Skilll_Slice_Offset, udg_Skilll_Slice_Degrees)
call CreateNUnitsAtLoc( 1, 039;hpea039;, udg_Skilll_Slice_Player, udg_Skilll_Slice_Point, udg_Skilll_Slice_Degrees )
call UnitApplyTimedLifeBJ( 1.30, 039;BTLF039;, GetLastCreatedUnit() )
call AddSpecialEffectTargetUnitBJ( "weapon", GetLastCreatedUnit(), "Abilities\\Weapons\\PhoenixMissile\\Phoenix_Missile_mini.mdl" )
call SetUnitVertexColorBJ( GetLastCreatedUnit(), 100, 100, 100, 50.00 )
call SetUnitAnimationWithRarity( GetLastCreatedUnit(), "slam", RARITY_RARE )
call TriggerSleepAction( 0.05 )
set in = in + 1
endloop
set udg_Skilll_Slice_Point = PolarProjectionBJ(udg_Skilll_Slice_Point, udg_Skilll_Slice_Offset, udg_Skilll_Slice_Degrees)
call SetUnitPositionLocFacingBJ( udg_Skilll_Slice_Unit, udg_Skilll_Slice_Point, udg_Skilll_Slice_Degrees )
call ShowUnitShow( udg_Skilll_Slice_Unit )
call SelectUnitForPlayerSingle( udg_Skilll_Slice_Unit, udg_Skilll_Slice_Player )
call SetUnitAnimationWithRarity( udg_Skilll_Slice_Unit, "slam", RARITY_RARE )
call QueueUnitAnimationBJ( udg_Skilll_Slice_Unit, "stand" )
endfunction
//===========================================================================
function InitTrig_Channel_Locals takes nothing returns nothing
set gg_trg_Channel_Locals = CreateTrigger( )
call TriggerRegisterAnyUnitEventBJ( gg_trg_Channel_Locals, EVENT_PLAYER_UNIT_SPELL_EFFECT )
call TriggerAddCondition( gg_trg_Channel_Locals, Condition( function Trig_Channel_Locals_Conditions ) )
call TriggerAddAction( gg_trg_Channel_Locals, function Trig_Channel_Locals_Actions )
endfunction