- Joined
- Apr 16, 2011
- Messages
- 158
CodeJASS:function Trig_Cross_Fire_Conditions takes nothing returns boolean if ( not ( GetSpellAbilityId() == 'A01I' ) ) then return false endif return true endfunction function Trig_Cross_Fire_Actions takes nothing returns nothing set udg_TempLoc51 = GetUnitLoc(GetTriggerUnit()) set udg_TempLoc54 = GetSpellTargetLoc() set udg_TempLoc52 = PolarProjectionBJ(udg_TempLoc51, 300.00, ( GetUnitFacing(GetTriggerUnit()) + 90.00 )) set udg_TempLoc53 = PolarProjectionBJ(udg_TempLoc51, 300.00, ( GetUnitFacing(GetTriggerUnit()) - 90.00 )) call CreateNUnitsAtLoc( 1, 'h00D', GetOwningPlayer(GetTriggerUnit()), udg_TempLoc52, GetUnitFacing(GetTriggerUnit()) ) set udg_UnitVarLastUnit[1] = bj_lastCreatedUnit call UnitApplyTimedLife(udg_UnitVarLastUnit[1],'BTLF', 1.50) call UnitAddAbility(udg_UnitVarLastUnit[1], 'A01L') call SetUnitAbilityLevel(udg_UnitVarLastUnit[1], 'A01L', GetUnitAbilityLevel(GetTriggerUnit(), 'A01I') ) call CreateNUnitsAtLoc( 1, 'h00D', GetOwningPlayer(GetTriggerUnit()), udg_TempLoc53, GetUnitFacing(GetTriggerUnit()) ) set udg_UnitVarLastUnit[2] = bj_lastCreatedUnit call UnitApplyTimedLife(udg_UnitVarLastUnit[2], 'BTLF', 1.50) call UnitAddAbility( udg_UnitVarLastUnit[2], 'A01L' ) call SetUnitAbilityLevel(udg_UnitVarLastUnit[2], 'A01L', GetUnitAbilityLevel(GetTriggerUnit(), 'A01I') ) call IssuePointOrderLoc( udg_UnitVarLastUnit[1], "carrionswarm", udg_TempLoc54 ) call IssuePointOrderLoc( udg_UnitVarLastUnit[2], "carrionswarm", udg_TempLoc54 ) set bj_lastCreatedEffect = AddSpecialEffectLoc("war3mapImported\\BlinkCaster.mdx", udg_TempLoc52) call DestroyEffect(bj_lastCreatedEffect) set bj_lastCreatedEffect = AddSpecialEffectLoc("war3mapImported\\BlinkCaster.mdx", udg_TempLoc53) call DestroyEffect(bj_lastCreatedEffect) call RemoveLocation (udg_TempLoc51) call RemoveLocation (udg_TempLoc52) call RemoveLocation (udg_TempLoc53) call RemoveLocation (udg_TempLoc54) set bj_lastPlayedSound = gg_snd_BlinkArrival1 if (gg_snd_BlinkArrival1 != null) then call StartSound(gg_snd_BlinkArrival1) endif set bj_lastPlayedSound = gg_snd_HealingSprayDeath1 if (gg_snd_HealingSprayDeath1 != null) then call StartSound(gg_snd_HealingSprayDeath1) endif set bj_lastPlayedSound = gg_snd_TheBlackArrow if (gg_snd_TheBlackArrow != null) then call StartSound(gg_snd_TheBlackArrow) endif endfunction //=========================================================================== function InitTrig_Wave takes nothing returns nothing set gg_trg_Wave = CreateTrigger( ) call TriggerRegisterAnyUnitEventBJ( gg_trg_Wave, EVENT_PLAYER_UNIT_SPELL_EFFECT ) call TriggerAddCondition( gg_trg_Wave, Condition( function Trig_Cross_Fire_Conditions ) ) call TriggerAddAction( gg_trg_Wave, function Trig_Cross_Fire_Actions ) endfunction
I read a little and I felt confident to transform some functions in native.

I know that has some functions that I didn't get to modify like "PolarProjectionBJ" and "CreateNUnitsAtLoc" would like to know how to do.

I know that that is not exactly jass
Thank you for her attention, if you has some reading clue I thank
how to improve?
