Name | Type | is_array | initial_value |
Buildings | group | Yes | |
Canopy | unit | No | |
FloatingText | texttag | Yes | |
Hero | unit | Yes | |
HeroRegions | rect | Yes | |
HeroSelectGroup | group | No | |
Judgement | unit | No | |
Kills | integer | Yes | |
Lives | integer | Yes | |
MultiVar | multiboard | No | |
PushBackUnitDeg | real | Yes | |
PushBackUnitTemp | unit | Yes | |
Sphere | unit | Yes | |
SphereAbil | abilcode | Yes | |
TempGroup | group | No | |
TempLoc | location | No | |
TempUnit | unit | Yes | |
Timer | timer | No | |
TimerNum | real | No |
function Trig_StartUpHeroSelection_Func001Func005002 takes nothing returns nothing
call SetUnitOwner( GetEnumUnit(), ConvertedPlayer(GetForLoopIndexA()), true )
endfunction
function Trig_StartUpHeroSelection_Actions takes nothing returns nothing
local integer i = 11
set bj_forLoopAIndex = 1
set bj_forLoopAIndexEnd = 8
loop
call CinematicModeBJ( false, GetPlayersAllies(ConvertedPlayer(GetForLoopIndexA())) )
exitwhen bj_forLoopAIndex > bj_forLoopAIndexEnd
loop
exitwhen IsUnitInGroup(udg_Hero[i], udg_HeroSelectGroup) == true
set i = GetRandomInt(0, 7)
endloop
call SetUnitAnimation( udg_Hero[i], "attack" )
call TriggerSleepAction( 1.00 )
call SetUnitPositionLoc( udg_Hero[i], GetRectCenter(udg_HeroRegions[i]) )
call ForGroupBJ( udg_Buildings[i], function Trig_StartUpHeroSelection_Func001Func005002 )
call SetUnitOwner( udg_Hero[i], ConvertedPlayer(GetForLoopIndexA()), false )
call ResetToGameCameraForPlayer( ConvertedPlayer(GetForLoopIndexA()), 0 )
call PanCameraToTimedLocForPlayer( ConvertedPlayer(GetForLoopIndexA()), GetUnitLoc(udg_Hero[i]), 0 )
call SelectUnitForPlayerSingle( udg_Hero[i], ConvertedPlayer(GetForLoopIndexA()) )
call GroupRemoveUnitSimple( udg_Hero[i], udg_HeroSelectGroup )
if ( GetPlayerController(ConvertedPlayer(GetForLoopIndexA())) != MAP_CONTROL_USER ) then
call RemoveUnit( udg_Hero[i] )
set udg_Lives[GetConvertedPlayerId(GetOwningPlayer(udg_Hero[i]))] = -1
call MultiboardSetItemValueBJ( udg_MultiVar, 1, GetForLoopIndexA(), "TRIGSTR_337" )
call MultiboardSetItemValueBJ( udg_MultiVar, 2, GetForLoopIndexA(), "TRIGSTR_338" )
endif
set bj_forLoopAIndex = bj_forLoopAIndex + 1
endloop
call FogEnableOn( )
call FogEnableOff( )
set bj_forLoopAIndex = 0
set bj_forLoopAIndexEnd = 7
loop
exitwhen bj_forLoopAIndex > bj_forLoopAIndexEnd
call PauseUnitBJ( false, udg_Hero[GetForLoopIndexA()] )
call DestroyTextTag( udg_FloatingText[GetForLoopIndexA()] )
set bj_forLoopAIndex = bj_forLoopAIndex + 1
endloop
endfunction
//===========================================================================
function InitTrig_StartUpHeroSelection takes nothing returns nothing
set gg_trg_StartUpHeroSelection = CreateTrigger( )
call TriggerRegisterTimerEventSingle( gg_trg_StartUpHeroSelection, 10.00 )
call TriggerAddAction( gg_trg_StartUpHeroSelection, function Trig_StartUpHeroSelection_Actions )
endfunction
function GetHeroSphere2 takes unit u returns integer
local integer i = 0
loop
exitwhen i>8
if (udg_Hero[i] == u) then
return i
else
set i=i+1
endif
endloop
return 9
endfunction
function Trig_SphereSystems2_Actions takes nothing returns nothing
local integer i = 0
local unit u = GetTriggerUnit()
local integer x = GetHeroSphere2(u)
if ( u == GetAttacker() ) then
call IssueTargetOrder( udg_Sphere[x], "attack", GetAttackedUnitBJ() )
else
if ( u == GetAttackedUnitBJ() ) then
else
if ( GetDyingUnit() == u ) then
call ExplodeUnitBJ( udg_Sphere[x] )
set udg_Sphere[x] = null
else
if ( GetRevivingUnit() == u ) then
set udg_Sphere[x] = CreateUnit( Player(13), 'Hblm', GetUnitX(u), GetUnitY(u), bj_UNIT_FACING )
call UnitAddAbilityBJ( udg_SphereAbil[x], udg_Sphere[x] )
call SetUnitInvulnerable( udg_Sphere[x], true )
call SetUnitPathing( udg_Sphere[x], false )
call SetUnitVertexColorBJ( udg_Sphere[x], 100, 100, 100, 100.00 )
call SetUnitPosition( udg_Sphere[x], GetUnitX(u), GetUnitY(u) )
endif
endif
endif
endif
set u = null
endfunction
//===========================================================================
function InitTrig_SphereSystem takes nothing returns nothing
set gg_trg_SphereSystem = CreateTrigger( )
call TriggerRegisterAnyUnitEventBJ( gg_trg_SphereSystem, EVENT_PLAYER_UNIT_DEATH )
call TriggerRegisterAnyUnitEventBJ( gg_trg_SphereSystem, EVENT_PLAYER_UNIT_ATTACKED )
call TriggerRegisterAnyUnitEventBJ( gg_trg_SphereSystem, EVENT_PLAYER_HERO_REVIVE_FINISH )
call TriggerAddAction( gg_trg_SphereSystem, function Trig_SphereSystems2_Actions )
endfunction
function GetHeroSphere takes unit u returns integer
local integer i = 0
loop
exitwhen i>8
if (udg_Hero[i] == u) then
return i
else
set i=i+1
endif
endloop
return 9
endfunction
function Trig_SphereSystem_Actions takes nothing returns nothing
local integer i = 0
loop
exitwhen i > 8
set udg_Sphere[i] = CreateUnit( Player(13), 'Hblm', GetUnitX(udg_Hero[i]), GetUnitY(udg_Hero[i]), bj_UNIT_FACING )
call SetUnitVertexColorBJ( udg_Sphere[i], 100, 100, 100, 100.00 )
call UnitAddAbilityBJ( udg_SphereAbil[i], udg_Sphere[i] )
call SetUnitInvulnerable( udg_Sphere[i], true )
call SetUnitPathing( udg_Sphere[i], false )
call SetUnitPosition( udg_Sphere[i], GetUnitX(udg_Hero[i]), GetUnitY(udg_Hero[i]) )
set i = i+1
endloop
call EnableTrigger( gg_trg_SphereSystem2 )
endfunction
//===========================================================================
function InitTrig_SphereSystem_Copy takes nothing returns nothing
set gg_trg_SphereSystem_Copy = CreateTrigger( )
call TriggerRegisterTimerEventSingle( gg_trg_SphereSystem_Copy, 25.00 )
call TriggerAddAction( gg_trg_SphereSystem_Copy, function Trig_SphereSystem_Actions )
endfunction
function Trig_Death_Conditions takes nothing returns boolean
if ( not ( IsUnitType(GetTriggerUnit(), UNIT_TYPE_HERO) == true ) ) then
return false
endif
return true
endfunction
function Trig_Death_Func002Func001C takes nothing returns boolean
if ( not ( udg_Lives[GetConvertedPlayerId(GetOwningPlayer(GetTriggerUnit()))] < 0 ) ) then
return false
endif
return true
endfunction
function Trig_Death_Func002C takes nothing returns boolean
if ( not ( udg_Lives[GetConvertedPlayerId(GetOwningPlayer(GetTriggerUnit()))] == 0 ) ) then
return false
endif
return true
endfunction
function Trig_Death_Actions takes nothing returns nothing
local integer i = 0
set udg_Lives[GetConvertedPlayerId(GetOwningPlayer(GetTriggerUnit()))] = ( udg_Lives[GetConvertedPlayerId(GetOwningPlayer(GetTriggerUnit()))] - 1 )
set udg_Kills[GetConvertedPlayerId(GetOwningPlayer(GetKillingUnitBJ()))] = ( udg_Kills[GetConvertedPlayerId(GetOwningPlayer(GetKillingUnitBJ()))] + 1 )
call MultiboardSetItemValueBJ( udg_MultiVar, 3, GetConvertedPlayerId(GetOwningPlayer(GetKillingUnitBJ()))+1, I2S(udg_Kills[GetConvertedPlayerId(GetOwningPlayer(GetKillingUnitBJ()))]) )
if ( Trig_Death_Func002C() ) then
call QuestMessageBJ( GetPlayersAll(), bj_QUESTMESSAGE_ALWAYSHINT, ( GetPlayerName(GetOwningPlayer(GetTriggerUnit())) + " has been killed! This is his last life!" ) )
call MultiboardSetItemValueBJ( udg_MultiVar, 2, GetConvertedPlayerId(GetOwningPlayer(GetTriggerUnit()))+1, I2S(udg_Lives[GetConvertedPlayerId(GetOwningPlayer(GetTriggerUnit()))]) )
loop
exitwhen udg_Hero[i] == GetTriggerUnit()
set i = i+1
endloop
call TriggerSleepAction( 15.00 )
call ReviveHeroLoc( udg_Hero[i], GetRectCenter(udg_HeroRegions[i]), false )
call SelectUnitForPlayerSingle( udg_Hero[i], GetOwningPlayer(udg_Hero[i]) )
call PanCameraToTimedLocForPlayer( GetOwningPlayer(udg_Hero[i]), GetUnitLoc(udg_Hero[i]), 0 )
call AddSpecialEffectTargetUnitBJ( "origin", udg_Hero[i], "Abilities\\Spells\\Human\\Resurrect\\ResurrectTarget.mdl" )
else
if ( Trig_Death_Func002Func001C() ) then
call QuestMessageBJ( GetPlayersAll(), bj_QUESTMESSAGE_ALWAYSHINT, ( GetPlayerName(GetOwningPlayer(GetTriggerUnit())) + " has been defeated! Their ghost will now wander the Earth." ) )
call CreateFogModifierRadiusLocBJ( true, GetOwningPlayer(GetTriggerUnit()), FOG_OF_WAR_VISIBLE, GetRectCenter(GetPlayableMapRect()), 99999.00 )
call MultiboardSetItemValueBJ( udg_MultiVar, 1, GetConvertedPlayerId(GetOwningPlayer(GetTriggerUnit()))+1, "TRIGSTR_337" )
call MultiboardSetItemValueBJ( udg_MultiVar, 2, GetConvertedPlayerId(GetOwningPlayer(GetTriggerUnit()))+1, "TRIGSTR_338" )
set udg_Lives[GetConvertedPlayerId(GetOwningPlayer(GetTriggerUnit()))] = -1
call CreateNUnitsAtLoc( 1, 'u000', GetOwningPlayer(GetTriggerUnit()), GetRectCenter(gg_rct_Arena), bj_UNIT_FACING )
else
call QuestMessageBJ( GetPlayersAll(), bj_QUESTMESSAGE_ALWAYSHINT, ( GetPlayerName(GetOwningPlayer(GetTriggerUnit())) + " has died. He will revive in his base in 15 seconds." ) )
call MultiboardSetItemValueBJ( udg_MultiVar, 2, GetConvertedPlayerId(GetOwningPlayer(GetTriggerUnit()))+1, I2S(udg_Lives[GetConvertedPlayerId(GetOwningPlayer(GetTriggerUnit()))]) )
loop
exitwhen udg_Hero[i] == GetTriggerUnit()
set i = i+1
endloop
call TriggerSleepAction( 15.00 )
call ReviveHeroLoc( udg_Hero[i], GetRectCenter(udg_HeroRegions[i]), false )
call SelectUnitForPlayerSingle( udg_Hero[i], GetOwningPlayer(udg_Hero[i]) )
call PanCameraToTimedLocForPlayer( GetOwningPlayer(udg_Hero[i]), GetUnitLoc(udg_Hero[i]), 0 )
call AddSpecialEffectTargetUnitBJ( "origin", udg_Hero[i], "Abilities\\Spells\\Human\\Resurrect\\ResurrectTarget.mdl" )
endif
endif
endfunction
//===========================================================================
function InitTrig_Death takes nothing returns nothing
set gg_trg_Death = CreateTrigger( )
call TriggerRegisterAnyUnitEventBJ( gg_trg_Death, EVENT_PLAYER_UNIT_DEATH )
call TriggerAddCondition( gg_trg_Death, Condition( function Trig_Death_Conditions ) )
call TriggerAddAction( gg_trg_Death, function Trig_Death_Actions )
endfunction
function Trig_Plague_Conditions takes nothing returns boolean
return ( GetSpellAbilityId() == 'A01I' )
endfunction
function Trig_Plague_Actions takes nothing returns nothing
local unit u = GetSpellTargetUnit()
call UnitAddAbilityBJ( 'A01Z', u )
call TriggerSleepAction( 10.00 )
if ( IsUnitAliveBJ(u) == true ) then
else
loop
exitwhen ( IsUnitAliveBJ(u) == true )
call TriggerSleepAction( 1 )
endloop
endif
call UnitRemoveAbilityBJ( 'A01Z', u )
endfunction
//===========================================================================
function InitTrig_Plague takes nothing returns nothing
set gg_trg_Plague = CreateTrigger( )
call TriggerRegisterAnyUnitEventBJ( gg_trg_Plague, EVENT_PLAYER_UNIT_SPELL_EFFECT )
call TriggerAddCondition( gg_trg_Plague, Condition( function Trig_Plague_Conditions ) )
call TriggerAddAction( gg_trg_Plague, function Trig_Plague_Actions )
endfunction
function Trig_Minion_Calling2_Conditions takes nothing returns boolean
if ( not ( GetUnitTypeId(GetAttacker()) == 'h001' ) ) then
return false
endif
return true
endfunction
function Trig_Minion_Calling2_Actions takes nothing returns nothing
local unit u = GetAttacker()
call TriggerSleepAction( 0.50 )
call ExplodeUnitBJ( u )
endfunction
//===========================================================================
function InitTrig_Minion_Calling2 takes nothing returns nothing
set gg_trg_Minion_Calling2 = CreateTrigger( )
call TriggerRegisterAnyUnitEventBJ( gg_trg_Minion_Calling2, EVENT_PLAYER_UNIT_ATTACKED )
call TriggerAddCondition( gg_trg_Minion_Calling2, Condition( function Trig_Minion_Calling2_Conditions ) )
call TriggerAddAction( gg_trg_Minion_Calling2, function Trig_Minion_Calling2_Actions )
endfunction
function Trig_Phase_Conditions takes nothing returns boolean
if ( not ( GetSpellAbilityId() == 'A002' ) ) then
return false
endif
return true
endfunction
function Trig_Phase_Actions takes nothing returns nothing
local unit u = GetTriggerUnit()
call ShowUnitHide( u )
call TriggerSleepAction( 1.00 )
call SetUnitPositionLoc( u, PolarProjectionBJ(GetUnitLoc(u), GetRandomReal(0, 600.00), GetRandomDirectionDeg()) )
call SetUnitLifeBJ( u, GetUnitStateSwap(UNIT_STATE_LIFE, u) + (GetUnitAbilityLevel( u, 'A002' )*50 ) )
call ShowUnitShow( u )
call SelectUnitForPlayerSingle( u, GetOwningPlayer(u) )
endfunction
//===========================================================================
function InitTrig_Phase takes nothing returns nothing
set gg_trg_Phase = CreateTrigger( )
call TriggerRegisterAnyUnitEventBJ( gg_trg_Phase, EVENT_PLAYER_UNIT_SPELL_EFFECT )
call TriggerAddCondition( gg_trg_Phase, Condition( function Trig_Phase_Conditions ) )
call TriggerAddAction( gg_trg_Phase, function Trig_Phase_Actions )
endfunction
function Trig_TouchOfTheNegativePlane_Conditions takes nothing returns boolean
if ( not ( GetSpellAbilityId() == 'A003' ) ) then
return false
endif
return true
endfunction
function Trig_TouchOfTheNegativePlane_Actions takes nothing returns nothing
local unit u = GetSpellTargetUnit()
local unit u2 = null
local unit u3 = GetTriggerUnit()
local integer i = 0
local texttag t = null
loop
if ( GetUnitStateSwap(UNIT_STATE_LIFE, u) >= 30 ) then
call SetUnitLifeBJ( u, GetUnitStateSwap(UNIT_STATE_LIFE, u) - 30 )
set t = CreateTextTagUnitBJ( "TRIGSTR_054", u, 10.00, 10, 100.00, 0.00, 0.00, 25.00 )
call TriggerSleepAction( 0.50 )
call DestroyTextTag( t )
call TriggerSleepAction( 0.50 )
set i = i+1
else
set u2 = CreateUnitAtLoc( GetOwningPlayer( u3 ), 'h002', GetUnitLoc( u ), bj_UNIT_FACING )
call IssueTargetOrder( u2, "frostnova", u )
set t = CreateTextTagUnitBJ( "TRIGSTR_086", u, 10.00, 10, 100.00, 0.00, 0.00, 25.00 )
call TriggerSleepAction( 0.50 )
call DestroyTextTag( t )
call ExplodeUnitBJ( u2 )
set i = 16
endif
exitwhen i > 12
endloop
set u = null
endfunction
//===========================================================================
function InitTrig_TouchOfTheNegativePlane takes nothing returns nothing
set gg_trg_TouchOfTheNegativePlane = CreateTrigger( )
call TriggerRegisterAnyUnitEventBJ( gg_trg_TouchOfTheNegativePlane, EVENT_PLAYER_UNIT_SPELL_EFFECT )
call TriggerAddCondition( gg_trg_TouchOfTheNegativePlane, Condition( function Trig_TouchOfTheNegativePlane_Conditions ) )
call TriggerAddAction( gg_trg_TouchOfTheNegativePlane, function Trig_TouchOfTheNegativePlane_Actions )
endfunction
function Trig_Crucify_Conditions takes nothing returns boolean
if ( not ( GetSpellAbilityId() == 'A009' ) ) then
return false
endif
return true
endfunction
function Trig_Crucify_Actions takes nothing returns nothing
local unit u = GetTriggerUnit()
local unit u2 = GetSpellTargetUnit()
local unit u3 = null
local texttag t = null
call TriggerSleepAction(3)
if ( GetUnitStateSwap(UNIT_STATE_LIFE, u2) >= ( ( 50.00 * I2R(GetUnitAbilityLevelSwapped('A009', u)) ) + 50 ) ) then
set t = CreateTextTagUnitBJ( "TRIGSTR_095", u2, 5.00, 10, 100, 100, 100, 0 )
call SetUnitLifeBJ( u2, GetUnitStateSwap(UNIT_STATE_LIFE, u2) - (50.00 * I2R(GetUnitAbilityLevelSwapped('A009', u)) + 50))
call TriggerSleepAction( 0.50 )
else
set t = CreateTextTagUnitBJ( "TRIGSTR_096", u2, 5.00, 10, 100, 100, 100, 0 )
set u3 = CreateUnitAtLoc( GetOwningPlayer(u), 'h002', GetUnitLoc(u2), bj_UNIT_FACING )
call IssueTargetOrder( u3, "frostnova", u2 )
call TriggerSleepAction( 0.50 )
call RemoveUnit( u3 )
endif
call DestroyTextTag( t )
endfunction
//===========================================================================
function InitTrig_Crucify takes nothing returns nothing
set gg_trg_Crucify = CreateTrigger( )
call TriggerRegisterAnyUnitEventBJ( gg_trg_Crucify, EVENT_PLAYER_UNIT_SPELL_EFFECT )
call TriggerAddCondition( gg_trg_Crucify, Condition( function Trig_Crucify_Conditions ) )
call TriggerAddAction( gg_trg_Crucify, function Trig_Crucify_Actions )
endfunction
function Trig_GeyserSpout_Conditions takes nothing returns boolean
if ( not ( GetSpellAbilityId() == 'A00E' ) ) then
return false
endif
return true
endfunction
function Trig_GeyserSpout_Actions takes nothing returns nothing
local location l = GetSpellTargetLoc()
local effect array e
local real r = 0.00
local integer i = 0
loop
call AddSpellEffectByIdLoc( 'A00E', EFFECT_TYPE_EFFECT, PolarProjectionBJ(l, 150.00, r) )
set e[i] = GetLastCreatedEffectBJ()
call TriggerSleepAction( 0.50 )
set i = i+1
set r = r + 45.00
exitwhen r > 360.00
endloop
set i = 0
loop
call DestroyEffect( e[i] )
set e[i] = null
set i = i+1
exitwhen i > 8
endloop
call RemoveLocation( l )
set l = null
endfunction
//===========================================================================
function InitTrig_GeyserSpout takes nothing returns nothing
set gg_trg_GeyserSpout = CreateTrigger( )
call TriggerRegisterAnyUnitEventBJ( gg_trg_GeyserSpout, EVENT_PLAYER_UNIT_SPELL_CAST )
call TriggerAddCondition( gg_trg_GeyserSpout, Condition( function Trig_GeyserSpout_Conditions ) )
call TriggerAddAction( gg_trg_GeyserSpout, function Trig_GeyserSpout_Actions )
endfunction
function Trig_Osmosis_Conditions takes nothing returns boolean
if ( not ( GetUnitAbilityLevelSwapped('A00G', gg_unit_H006_0071) > 0 ) ) then
return false
endif
return true
endfunction
function Trig_Osmosis_Actions takes nothing returns nothing
local integer i = GetRandomInt(1, 10)
local texttag t = null
if ( i <= GetUnitAbilityLevelSwapped('A00G', gg_unit_H006_0071) ) then
call SetUnitVertexColorBJ( gg_unit_H006_0071, 100, 100, 100, 50.00 )
call SetUnitLifeBJ( GetTriggerUnit(), ( GetUnitStateSwap(UNIT_STATE_LIFE, GetTriggerUnit()) + GetEventDamage() ) )
set t = CreateTextTagUnitBJ( "TRIGSTR_189", gg_unit_H006_0071, 0, 10, 100, 0.00, 0.00, 0 )
call ShowTextTagForceBJ( true, GetLastCreatedTextTag(), GetPlayersAll() )
call TriggerSleepAction( 1.00 )
call DestroyTextTag( t )
call SetUnitVertexColorBJ( gg_unit_H006_0071, 50, 50, 100, 0 )
else
call DoNothing( )
endif
endfunction
//===========================================================================
function InitTrig_Osmosis takes nothing returns nothing
set gg_trg_Osmosis = CreateTrigger( )
call TriggerRegisterUnitEvent( gg_trg_Osmosis, gg_unit_H006_0071, EVENT_UNIT_DAMAGED )
call TriggerAddCondition( gg_trg_Osmosis, Condition( function Trig_Osmosis_Conditions ) )
call TriggerAddAction( gg_trg_Osmosis, function Trig_Osmosis_Actions )
endfunction
function Trig_Wavebreak_Conditions takes nothing returns boolean
if ( not ( GetSpellAbilityId() == 'A00H' ) ) then
return false
endif
return true
endfunction
function Trig_Wavebreak_Actions takes nothing returns nothing
local unit u = GetTriggerUnit()
local integer i = 0
loop
exitwhen i > 4
call CreateNUnitsAtLoc( 1, 'h00B', GetOwningPlayer(u), GetUnitLoc(u), bj_UNIT_FACING )
call IssuePointOrderLoc( GetLastCreatedUnit(), "carrionswarm", PolarProjectionBJ(GetUnitLoc(u), 256, GetUnitFacing(u)) )
call UnitApplyTimedLifeBJ( 1.00, 'BTLF', GetLastCreatedUnit() )
call TriggerSleepAction( 1.00 )
set i = i+1
endloop
endfunction
//===========================================================================
function InitTrig_Wavebreak takes nothing returns nothing
set gg_trg_Wavebreak = CreateTrigger( )
call TriggerRegisterAnyUnitEventBJ( gg_trg_Wavebreak, EVENT_PLAYER_UNIT_SPELL_EFFECT )
call TriggerAddCondition( gg_trg_Wavebreak, Condition( function Trig_Wavebreak_Conditions ) )
call TriggerAddAction( gg_trg_Wavebreak, function Trig_Wavebreak_Actions )
endfunction
function Trig_Inflame_Conditions takes nothing returns boolean
if ( not ( GetSpellAbilityId() == 'A00L' ) ) then
return false
endif
return true
endfunction
function Trig_Inflame_Func002003001003 takes nothing returns boolean
return ( IsUnitEnemy(GetFilterUnit(), GetOwningPlayer(gg_unit_H005_0072)) == true )
endfunction
function Trig_Inflame_Actions takes nothing returns nothing
local unit u = GetTriggerUnit()
local unit u2 = null
local unit u3 = null
local group g = GetUnitsInRangeOfLocMatching(250.00, GetUnitLoc(u), Condition(function Trig_Inflame_Func002003001003))
set u2 = CreateUnitAtLoc( GetOwningPlayer(u), 'h00C', GetUnitLoc(u), bj_UNIT_FACING )
loop
exitwhen GroupPickRandomUnit(g) == null
set u3 = GroupPickRandomUnit(g)
call IssueTargetOrder( u2, "unholyfrenzy", u3 )
call TriggerSleepAction( 0.30 )
call GroupRemoveUnitSimple( u3, g )
endloop
call ExplodeUnitBJ( u2 )
set u = null
set u2 = null
set u3 = null
set g = null
call DestroyGroup( g )
endfunction
//===========================================================================
function InitTrig_Inflame takes nothing returns nothing
set gg_trg_Inflame = CreateTrigger( )
call TriggerRegisterAnyUnitEventBJ( gg_trg_Inflame, EVENT_PLAYER_UNIT_SPELL_EFFECT )
call TriggerAddCondition( gg_trg_Inflame, Condition( function Trig_Inflame_Conditions ) )
call TriggerAddAction( gg_trg_Inflame, function Trig_Inflame_Actions )
endfunction
function Trig_Erosion_Conditions takes nothing returns boolean
if ( not ( GetSpellAbilityId() == 'A02R' ) ) then
return false
endif
return true
endfunction
function Trig_Erosion_Actions takes nothing returns nothing
local unit u = GetSpellTargetUnit()
local unit u2 = GetTriggerUnit()
call ModifyHeroStat( bj_HEROSTAT_STR, u, bj_MODIFYMETHOD_SUB, ( 3 * GetUnitAbilityLevelSwapped('A02R', u2) ) )
call ModifyHeroStat( bj_HEROSTAT_INT, u, bj_MODIFYMETHOD_ADD, ( 1 * GetUnitAbilityLevelSwapped('A02R', u2) ) )
call TriggerSleepAction( 7.50 )
if ( IsUnitAliveBJ(u) == false ) then
loop
exitwhen ( IsUnitAliveBJ(u) == true )
call TriggerSleepAction( 1 )
endloop
endif
call ModifyHeroStat( bj_HEROSTAT_STR, u, bj_MODIFYMETHOD_ADD, ( 3 * GetUnitAbilityLevelSwapped('A02R', u2) ) )
call ModifyHeroStat( bj_HEROSTAT_INT, u, bj_MODIFYMETHOD_SUB, ( 1 * GetUnitAbilityLevelSwapped('A02R', u2) ) )
endfunction
//===========================================================================
function InitTrig_Erosion takes nothing returns nothing
set gg_trg_Erosion = CreateTrigger( )
call TriggerRegisterAnyUnitEventBJ( gg_trg_Erosion, EVENT_PLAYER_UNIT_SPELL_EFFECT )
call TriggerAddCondition( gg_trg_Erosion, Condition( function Trig_Erosion_Conditions ) )
call TriggerAddAction( gg_trg_Erosion, function Trig_Erosion_Actions )
endfunction
function Trig_Gust_Conditions takes nothing returns boolean
if ( not ( GetSpellAbilityId() == 'A00Y' ) ) then
return false
endif
return true
endfunction
function Trig_Gust_Actions takes nothing returns nothing
local unit u = GetSpellTargetUnit()
local unit u2 = GetTriggerUnit()
call TriggerSleepAction( 0.5 )
call SetUnitPositionLoc( u, PolarProjectionBJ(GetUnitLoc(u), 300.00, AngleBetweenPoints(GetUnitLoc(u2), GetUnitLoc(u)) ) )
set u = null
set u2 = null
endfunction
//===========================================================================
function InitTrig_Gust takes nothing returns nothing
set gg_trg_Gust = CreateTrigger( )
call TriggerRegisterAnyUnitEventBJ( gg_trg_Gust, EVENT_PLAYER_UNIT_SPELL_EFFECT )
call TriggerAddCondition( gg_trg_Gust, Condition( function Trig_Gust_Conditions ) )
call TriggerAddAction( gg_trg_Gust, function Trig_Gust_Actions )
endfunction