- Joined
- Oct 16, 2011
- Messages
- 296
Can someone check this if there's a leak. Also, I know there's a lot of improvement to this, so if someone can improve or make it shorter please do so
Edit: as KILLCIDE says,
Edit: as KILLCIDE says,
Post the triggers please. Not everyone has the World Editor on them.
-
Shockwave
-
Events
- Unit - A unit Starts the effect of an ability
-
Conditions
- (Ability being cast) Equal to Shockwave (Trigger)
-
Actions
- Set SW_Max = (SW_Max + 1)
- Set SW_Caster[SW_Max] = (Triggering unit)
- Set SW_WaveEffect[SW_Max] = Abilities\Spells\Orc\Shockwave\ShockwaveMissile.mdl
- Set SW_WaveEffectL[SW_Max] = Abilities\Spells\Other\Incinerate\FireLordDeathExplode.mdl
- Set SW_AllowFXLoop[SW_Max] = True
- Set SW_PointCaster[SW_Max] = (Position of (Triggering unit))
- Set SW_PointTarget[SW_Max] = (Target point of ability being cast)
- Set SW_Lvl[SW_Max] = (Level of (Ability being cast) for (Triggering unit))
- Set SW_Damage[1] = 10.00
- Set SW_Damage[2] = 20.00
- Set SW_Damage[3] = 30.00
- Set SW_DamageFinal[1] = 200.00
- Set SW_DamageFinal[2] = 300.00
- Set SW_DamageFinal[3] = 400.00
- Set SW_AreaInitial[1] = 125.00
- Set SW_AreaInitial[2] = 125.00
- Set SW_AreaInitial[3] = 125.00
- Set SW_AreaFinal[1] = 125.00
- Set SW_AreaFinal[2] = 125.00
- Set SW_AreaFinal[3] = 125.00
- Set SW_Speed[1] = 1050.00
- Set SW_Speed[2] = 1050.00
- Set SW_Speed[3] = 1050.00
- Set SW_Distance[1] = 400.00
- Set SW_Distance[2] = 1000.00
- Set SW_Distance[3] = 1800.00
- Unit - Create 1 Dummy for (Owner of SW_Caster[SW_Max]) at SW_PointCaster[SW_Max] facing SW_PointTarget[SW_Max]
- Set SW_Dummy[SW_Max] = (Last created unit)
- Unit - Turn collision for SW_Dummy[SW_Max] Off
- Animation - Change SW_Dummy[SW_Max]'s vertex coloring to (100.00%, 100.00%, 100.00%) with 100.00% transparency
- Set SW_AreaGrowth[SW_Max] = ((SW_AreaFinal[SW_Lvl[SW_Max]] - SW_AreaInitial[SW_Lvl[SW_Max]]) / ((1.00 / 0.03) x (SW_Distance[SW_Lvl[SW_Max]] / SW_Speed[SW_Lvl[SW_Max]])))
- Set SW_AreaCurrent[SW_Max] = SW_AreaInitial[SW_Lvl[SW_Max]]
- Special Effect - Create a special effect attached to the origin of SW_Dummy[SW_Max] using SW_WaveEffect[SW_Max]
- Custom script: set udg_SW_GroupDone[udg_SW_Max] = CreateGroup()
- Set SW_DistanceX[SW_Max] = SW_Distance[SW_Lvl[SW_Max]]
- Set SW_SpeedX[SW_Max] = SW_Speed[SW_Lvl[SW_Max]]
- Set SW_DamageX[SW_Max] = SW_Damage[SW_Lvl[SW_Max]]
- Set SW_DamageFinalX[SW_Max] = SW_DamageFinal[SW_Lvl[SW_Max]]
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
- SW_Max Equal to 1
-
Then - Actions
- Trigger - Turn on Shockwave Loop <gen>
- Else - Actions
-
If - Conditions
-
Events
-
Carrion Swarm
-
Events
- Unit - A unit Starts the effect of an ability
-
Conditions
- (Ability being cast) Equal to Carrion Swarm (Trigger)
-
Actions
- Set SW_Max = (SW_Max + 1)
- Set SW_Caster[SW_Max] = (Triggering unit)
- Set SW_WaveEffect[SW_Max] = Abilities\Spells\Undead\CarrionSwarm\CarrionSwarmMissile.mdl
- Set SW_WaveEffectL[SW_Max] = Abilities\Spells\Undead\DarkRitual\DarkRitualTarget.mdl
- Set SW_AllowFXLoop[SW_Max] = True
- Set SW_PointCaster[SW_Max] = (Position of (Triggering unit))
- Set SW_PointTarget[SW_Max] = (Target point of ability being cast)
- Set SW_Lvl[SW_Max] = (Level of (Ability being cast) for (Triggering unit))
- Set SW_Damage[1] = 100.00
- Set SW_Damage[2] = 200.00
- Set SW_Damage[3] = 300.00
- Set SW_DamageFinal[1] = 0.00
- Set SW_DamageFinal[2] = 0.00
- Set SW_DamageFinal[3] = 0.00
- Set SW_AreaInitial[1] = 100.00
- Set SW_AreaInitial[2] = 100.00
- Set SW_AreaInitial[3] = 100.00
- Set SW_AreaFinal[1] = 100.00
- Set SW_AreaFinal[2] = 300.00
- Set SW_AreaFinal[3] = 500.00
- Set SW_Speed[1] = 1100.00
- Set SW_Speed[2] = 1100.00
- Set SW_Speed[3] = 1100.00
- Set SW_Distance[1] = 800.00
- Set SW_Distance[2] = 800.00
- Set SW_Distance[3] = 800.00
- Unit - Create 1 Dummy for (Owner of SW_Caster[SW_Max]) at SW_PointCaster[SW_Max] facing SW_PointTarget[SW_Max]
- Set SW_Dummy[SW_Max] = (Last created unit)
- Unit - Turn collision for SW_Dummy[SW_Max] Off
- Animation - Change SW_Dummy[SW_Max]'s vertex coloring to (100.00%, 100.00%, 100.00%) with 100.00% transparency
- Set SW_AreaGrowth[SW_Max] = ((SW_AreaFinal[SW_Lvl[SW_Max]] - SW_AreaInitial[SW_Lvl[SW_Max]]) / ((1.00 / 0.03) x (SW_Distance[SW_Lvl[SW_Max]] / SW_Speed[SW_Lvl[SW_Max]])))
- Set SW_AreaCurrent[SW_Max] = SW_AreaInitial[SW_Lvl[SW_Max]]
- Special Effect - Create a special effect attached to the origin of SW_Dummy[SW_Max] using SW_WaveEffect[SW_Max]
- Custom script: set udg_SW_GroupDone[udg_SW_Max] = CreateGroup()
- Set SW_DistanceX[SW_Max] = SW_Distance[SW_Lvl[SW_Max]]
- Set SW_SpeedX[SW_Max] = SW_Speed[SW_Lvl[SW_Max]]
- Set SW_DamageX[SW_Max] = SW_Damage[SW_Lvl[SW_Max]]
- Set SW_DamageFinalX[SW_Max] = SW_DamageFinal[SW_Lvl[SW_Max]]
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
- SW_Max Equal to 1
-
Then - Actions
- Trigger - Turn on Shockwave Loop <gen>
- Else - Actions
-
If - Conditions
-
Events
-
Shockwave Loop
-
Events
- Time - Every 0.03 seconds of game time
- Conditions
-
Actions
-
For each (Integer SW_Loop) from 1 to SW_Max, do (Actions)
-
Loop - Actions
- Set SW_DistanceX[SW_Loop] = (SW_DistanceX[SW_Loop] - (SW_SpeedX[SW_Loop] / (1.00 / 0.03)))
- Set SW_Angle[SW_Loop] = (Facing of SW_Dummy[SW_Loop])
- Set SW_NextPoint[SW_Loop] = (Position of SW_Dummy[SW_Loop])
- Set SW_NextPointMove[SW_Loop] = (SW_NextPoint[SW_Loop] offset by (SW_SpeedX[SW_Loop] / (1.00 / 0.03)) towards SW_Angle[SW_Loop] degrees)
- Set SW_AreaCurrent[SW_Loop] = (SW_AreaCurrent[SW_Loop] + SW_AreaGrowth[SW_Loop])
- Set SW_Group[SW_Loop] = (Units within SW_AreaCurrent[SW_Loop] of SW_NextPointMove[SW_Loop] matching ((((Matching unit) belongs to an enemy of (Owner of SW_Caster[SW_Loop])) Equal to True) and ((((Matching unit) is alive) Equal to True) and (((Matching unit) is in SW_GroupDone[SW_Loo
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
- SW_AllowFXLoop[SW_Loop] Equal to True
-
Then - Actions
- Special Effect - Create a special effect at SW_NextPoint[SW_Loop] using SW_WaveEffectL[SW_Loop]
- Special Effect - Destroy (Last created special effect)
- Else - Actions
-
If - Conditions
- Unit - Move SW_Dummy[SW_Loop] instantly to SW_NextPointMove[SW_Loop], facing SW_Angle[SW_Loop] degrees
-
Unit Group - Pick every unit in SW_Group[SW_Loop] and do (Actions)
-
Loop - Actions
- Unit - Cause SW_Caster[SW_Loop] to damage (Picked unit), dealing SW_DamageX[SW_Loop] damage of attack type Spells and damage type Universal
- Unit Group - Add (Picked unit) to SW_GroupDone[SW_Loop]
-
Loop - Actions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
- SW_DistanceX[SW_Loop] Less than or equal to 0.00
-
Then - Actions
- Set SW_GroupFinal = (Units within SW_AreaCurrent[SW_Loop] of SW_NextPointMove[SW_Loop] matching ((((Matching unit) belongs to an enemy of (Owner of SW_Caster[SW_Loop])) Equal to True) and (((Matching unit) is alive) Equal to True)))
-
Unit Group - Pick every unit in SW_GroupFinal and do (Actions)
-
Loop - Actions
- Unit - Cause SW_Caster[SW_Loop] to damage (Picked unit), dealing SW_DamageFinalX[SW_Loop] damage of attack type Spells and damage type Universal
-
Loop - Actions
- -------- Only remove existing groups. --------
- Custom script: call DestroyGroup( udg_SW_GroupFinal )
- Set SW_GroupDone[SW_Loop] = SW_GroupDone[SW_Max]
- Unit Group - Remove all units of SW_GroupDone[SW_Max] from SW_GroupDone[SW_Max]
- Set SW_Caster[SW_Loop] = SW_Caster[SW_Max]
- Set SW_Caster[SW_Max] = No unit
- Unit - Kill SW_Dummy[SW_Loop]
- Set SW_Dummy[SW_Loop] = SW_Dummy[SW_Max]
- Set SW_Dummy[SW_Max] = No unit
- -------- Must move all members of an object during object move operation. --------
- Set SW_DistanceX[SW_Loop] = SW_DistanceX[SW_Max]
- Set SW_SpeedX[SW_Loop] = SW_SpeedX[SW_Max]
- Set SW_DamageX[SW_Loop] = SW_DamageX[SW_Max]
- Set SW_DamageFinalX[SW_Loop] = SW_DamageFinalX[SW_Max]
- Set SW_AreaCurrent[SW_Loop] = SW_AreaCurrent[SW_Max]
- Set SW_Lvl[SW_Loop] = SW_Lvl[SW_Max]
- Set SW_Max = (SW_Max - 1)
- Set SW_Loop = (SW_Loop - 1)
- Else - Actions
-
If - Conditions
- Custom script: call RemoveLocation(udg_SW_NextPoint[udg_SW_Loop])
- Custom script: call RemoveLocation(udg_SW_NextPointMove[udg_SW_Loop])
- Custom script: call DestroyGroup( udg_SW_Group[udg_SW_Loop] )
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
- SW_Max Equal to 0
-
Then - Actions
- Trigger - Turn off (This trigger)
- Else - Actions
-
If - Conditions
-
Loop - Actions
-
For each (Integer SW_Loop) from 1 to SW_Max, do (Actions)
-
Events
-
Shockwave Recover
-
Events
- Unit - A unit Dies
-
Conditions
- (Unit-type of (Triggering unit)) Equal to Dummy
-
Actions
- Unit - Remove (Triggering unit) from the game
-
Events
Attachments
Last edited: