1. Are you planning to upload your awesome spell or system to Hive? Please review the rules here.
    Dismiss Notice
  2. Fill your cup and take your pick among the maps best suited for this year's Hive Cup. The 6th Melee Mapping Contest Poll is up!
    Dismiss Notice
  3. Shoot to thrill, play to kill. Sate your hunger with the 33rd Modeling Contest!
    Dismiss Notice
  4. Do you hear boss music? It's the 17th Mini Mapping Contest!
    Dismiss Notice
  5. Check out the Staff job openings thread.
    Dismiss Notice
Dismiss Notice
60,000 passwords have been reset on July 8, 2019. If you cannot login, read this.

Trigger Viewer

Chaosphere v2.4.w3x
Variables
Chaosphere Spell
Chaosphere Init
Chaosphere Cast
Chaosphere Function
Chaosphere Effect
List of Current Buffs/Effects
Adding New Buffs/Effects
How To Import
Testing Purposes
Testing Init
Testing Revive
Enter map-specific custom script code below. This text will be included in the map script after variables are declared and before any trigger code.

		
Name Type Is Array Initial Value
chaospherecastinggroup group No
chaospherechance real Yes
chaosphereemptyugroup group No
chaospherehashtable hashtable No
chaospherenumbereffects integer No
chaospherepickedunit handle No
chaospheretargetgroup group No
chaospheretotalchance real No
tempinteger integer No
temppoint location No
temppoint2 location No
temppoint3 location No
tempreal real No
tempreal2 real No
tempugroup group No
tempugroup2 group No
tempunit2 unit No
Creates the Hashtable.
Chaosphere Init
  Events
    Map initialization
  Conditions
  Actions
    Hashtable - Create a hashtable
    Set VariableSet chaospherehashtable = (Last created hashtable)
    -------- HASHTABLEINFO --------
    -------- 1-8 = Dummy Units --------
    -------- 9 = Casting Stage (Integer) --------
    -------- 10 = Units in Sphere (Unitgroup) --------
    -------- 11 = Owner of Casting Unit --------
    -------- 12 = Duration (Real) --------
    -------- 13-14 = Casting Location --------
    -------- - --------
    Set VariableSet chaospherenumbereffects = 10
    Set VariableSet chaospherechance[1] = 15.00
    Set VariableSet chaospherechance[2] = 15.00
    Set VariableSet chaospherechance[3] = 10.00
    Set VariableSet chaospherechance[4] = 10.00
    Set VariableSet chaospherechance[5] = 10.00
    Set VariableSet chaospherechance[6] = 10.00
    Set VariableSet chaospherechance[7] = 10.00
    Set VariableSet chaospherechance[8] = 10.00
    Set VariableSet chaospherechance[9] = 5.00
    Set VariableSet chaospherechance[10] = 5.00
    -------- EFFECT INFO --------
    -------- 1 = Warp --------
    -------- 2 = Confusion --------
    -------- 3 = Voodoo Curse --------
    -------- 4 = Blind --------
    -------- 5 = Shadow Strike --------
    -------- 6 = Shock --------
    -------- 7 = Slow --------
    -------- 8 = Silence --------
    -------- 9 = Sleep --------
    -------- 10 = Hex --------
    -------- - --------
    For each (Integer A) from 1 to chaospherenumbereffects, do (Actions)
      Loop - Actions
        Set VariableSet chaospherechance[(Integer A)] = (chaospherechance[(Integer A)] + chaospherechance[((Integer A) - 1)])
        Set VariableSet chaospheretotalchance = (chaospheretotalchance + chaospherechance[(Integer A)])
Runs when the spell is first casted. It creates some dummy units and records information into the hashtable.

IMPORTING: Condition should read: "(Ability being cast) Equal to Chaosphere"
Chaosphere Cast
  Events
    Unit - A unit Starts the effect of an ability
  Conditions
    (Ability being cast) Equal to Chaosphere
  Actions
    Set VariableSet temppoint = (Position of (Triggering unit))
    Unit Group - Add (Triggering unit) to chaospherecastinggroup
    -------- Save Hashtable Data --------
    Hashtable - Save 1 as 9 of (Key (Casting unit).) in chaospherehashtable.
    Hashtable - Save Handle Ofchaosphereemptyugroup as 10 of (Key (Triggering unit).) in chaospherehashtable.
    Hashtable - Save Handle Of(Owner of (Triggering unit)) as 11 of (Key (Triggering unit).) in chaospherehashtable.
    Hashtable - Save 0.00 as 12 of (Key (Triggering unit).) in chaospherehashtable.
    Hashtable - Save (X of temppoint) as 13 of (Key (Triggering unit).) in chaospherehashtable.
    Hashtable - Save (Y of temppoint) as 14 of (Key (Triggering unit).) in chaospherehashtable.
    For each (Integer A) from 1 to 8, do (Actions)
      Loop - Actions
        Set VariableSet temppoint2 = (temppoint offset by 50.00 towards (45.00 x (Real((Integer A)))) degrees.)
        -------- IMPORTING: Next Event should read: "Unit - Create 1 Chaosorb for..." --------
        Unit - Create 1.Chaosorb for (Owner of (Triggering unit)) at temppoint2 facing (45.00 x (Real((Integer A)))) degrees
        Unit - Add a 24.00 second Generic expiration timer to (Last created unit)
        Hashtable - Save Handle Of(Last created unit) as (Integer A) of (Key (Triggering unit).) in chaospherehashtable.
        Custom script: call RemoveLocation (udg_temppoint2)
    Custom script: call RemoveLocation (udg_temppoint)
    If (All Conditions are True) then do (Then Actions) else do (Else Actions)
      If - Conditions
        (Number of units in chaospherecastinggroup) Equal to 1
      Then - Actions
        Trigger - Turn on Chaosphere_Function <gen>
      Else - Actions
Runs for each unit currently casting the spell. It add/removes enemy units from the effect ground, moves the effect dummies, progresses and terminates the spell's effects.
Chaosphere Function
  Events
    Time - Every 0.05 seconds of game time
  Conditions
  Actions
    Unit Group - Pick every unit in chaospherecastinggroup and do (Actions)
      Loop - Actions
        Set VariableSet chaospherepickedunit = (Picked unit)
        Set VariableSet tempinteger = (Load 9 of (Key (Picked unit).) from chaospherehashtable.)
        -------- Adding/Removing Units from Target Group --------
        Set VariableSet temppoint3 = (Point((Load 13 of (Key (Picked unit).) from chaospherehashtable.), (Load 14 of (Key (Picked unit).) from chaospherehashtable.)))
        Set VariableSet tempugroup = (Units within 500.00 of temppoint3.)
        Unit Group - Pick every unit in tempugroup and do (Actions)
          Loop - Actions
            If (All Conditions are True) then do (Then Actions) else do (Else Actions)
              If - Conditions
                (Level of Spell Immunity for (Picked unit)) Equal to 0
                tempinteger Equal to 2
                ((Picked unit) is dead) Equal to False
                ((Owner of (Picked unit)) is an enemy of (Load 11 of (Key chaospherepickedunit.) in chaospherehashtable.).) Equal to True
                ((Picked unit) is in (Load 10 of (Key chaospherepickedunit.) in chaospherehashtable.).) Equal to False
              Then - Actions
                Unit Group - Add (Picked unit) to (Load 10 of (Key chaospherepickedunit.) in chaospherehashtable.)
                Unit Group - Add (Picked unit) to chaospheretargetgroup
              Else - Actions
        Unit Group - Pick every unit in (Load 10 of (Key chaospherepickedunit.) in chaospherehashtable.) and do (Actions)
          Loop - Actions
            If (All Conditions are True) then do (Then Actions) else do (Else Actions)
              If - Conditions
                Or - Any (Conditions) are true
                  Conditions
                    (Level of Spell Immunity for (Picked unit)) Not equal to 0
                    tempinteger Not equal to 2
                    ((Picked unit) is dead) Equal to True
                    ((Picked unit) is in tempugroup.) Equal to False
              Then - Actions
                Unit Group - Remove (Picked unit) from (Load 10 of (Key chaospherepickedunit.) in chaospherehashtable.).
                Unit Group - Remove (Picked unit) from chaospheretargetgroup.
              Else - Actions
        Custom script: call DestroyGroup (udg_tempugroup)
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
          If - Conditions
            (Number of units in chaospheretargetgroup) Greater than or equal to 1
          Then - Actions
            Trigger - Turn on Chaosphere_Effect <gen>
          Else - Actions
            Trigger - Turn off Chaosphere_Effect <gen>
        -------- Moving the Effect Dummies --------
        For each (Integer A) from 1 to 8, do (Actions)
          Loop - Actions
            If (All Conditions are True) then do (Then Actions) else do (Else Actions)
              If - Conditions
                tempinteger Equal to 1
              Then - Actions
                Set VariableSet tempunit2 = (Load (Integer A) of (Key (Picked unit).) in chaospherehashtable.)
                Set VariableSet temppoint = (Position of tempunit2)
                Set VariableSet temppoint2 = (temppoint3 offset by ((Distance between temppoint3 and temppoint) + 11.25) towards ((Angle from temppoint3 to temppoint) + 6.00) degrees.)
                Unit - Move tempunit2 instantly to temppoint2
                Custom script: call RemoveLocation (udg_temppoint)
                Custom script: call RemoveLocation (udg_temppoint2)
              Else - Actions
        For each (Integer A) from 1 to 8, do (Actions)
          Loop - Actions
            If (All Conditions are True) then do (Then Actions) else do (Else Actions)
              If - Conditions
                tempinteger Equal to 2
              Then - Actions
                Set VariableSet tempunit2 = (Load (Integer A) of (Key (Picked unit).) in chaospherehashtable.)
                Set VariableSet temppoint = (Position of tempunit2)
                Set VariableSet temppoint2 = (temppoint3 offset by ((Distance between temppoint3 and temppoint) + 0.00) towards ((Angle from temppoint3 to temppoint) + 6.00) degrees.)
                Unit - Move tempunit2 instantly to temppoint2
                Custom script: call RemoveLocation (udg_temppoint)
                Custom script: call RemoveLocation (udg_temppoint2)
              Else - Actions
        For each (Integer A) from 1 to 8, do (Actions)
          Loop - Actions
            If (All Conditions are True) then do (Then Actions) else do (Else Actions)
              If - Conditions
                tempinteger Equal to 3
              Then - Actions
                Set VariableSet tempunit2 = (Load (Integer A) of (Key (Picked unit).) in chaospherehashtable.)
                Set VariableSet temppoint = (Position of tempunit2)
                Set VariableSet temppoint2 = (temppoint3 offset by ((Distance between temppoint3 and temppoint) - 11.25) towards ((Angle from temppoint3 to temppoint) + 6.00) degrees.)
                Unit - Move tempunit2 instantly to temppoint2
                Custom script: call RemoveLocation (udg_temppoint)
                Custom script: call RemoveLocation (udg_temppoint2)
              Else - Actions
        Set VariableSet tempreal = (Load 12 of (Key (Picked unit).) from chaospherehashtable.)
        Set VariableSet tempinteger = (Load 9 of (Key chaospherepickedunit.) from chaospherehashtable.)
        -------- Progressing the Stages of the Spell --------
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
          If - Conditions
            tempreal Greater than or equal to 2.00
            tempinteger Equal to 1
          Then - Actions
            Hashtable - Save 2 as 9 of (Key (Picked unit).) in chaospherehashtable.
            -------- IMPORTING: Next Event should read: "Unit - Create 1 Chaosphere for..." --------
            Unit - Create 1.Chaosphere for (Owner of (Picked unit)) at temppoint3 facing Default building facing degrees
            Unit - Add a 20.00 second Generic expiration timer to (Last created unit)
            -------- IMPORTING: Next Event should read: "Unit - Create 1 Chaosphere for..." --------
            Unit - Create 1.Chaosphere for (Owner of (Picked unit)) at temppoint3 facing Default building facing degrees
            Unit - Add a 20.00 second Generic expiration timer to (Last created unit)
          Else - Actions
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
          If - Conditions
            tempreal Greater than or equal to 22.00
            tempinteger Equal to 2
          Then - Actions
            Hashtable - Save 3 as 9 of (Key (Picked unit).) in chaospherehashtable.
          Else - Actions
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
          If - Conditions
            tempreal Greater than or equal to 24.00
            tempinteger Equal to 3
          Then - Actions
            Hashtable - Save 0 as 9 of (Key (Picked unit).) in chaospherehashtable.
            Unit Group - Remove (Picked unit) from chaospherecastinggroup.
            If (All Conditions are True) then do (Then Actions) else do (Else Actions)
              If - Conditions
                (Number of units in chaospherecastinggroup) Equal to 0
              Then - Actions
                Trigger - Turn off (This trigger)
              Else - Actions
            Hashtable - Clear all child hashtables of child (Key (Picked unit).) in chaospherehashtable.
            Custom script: call DestroyGroup (LoadGroupHandleBJ(10, GetHandleIdBJ(GetEnumUnit()), udg_chaospherehashtable))
            Custom script: call RemoveLocation (udg_temppoint3)
            Skip remaining actions
          Else - Actions
        Hashtable - Save (tempreal + 0.05) as 12 of (Key (Picked unit).) in chaospherehashtable.
        Custom script: call RemoveLocation (udg_temppoint3)
Runs for each enemy being effected by the spell.
Chaosphere Effect
  Events
    Time - Every 0.20 seconds of game time
  Conditions
  Actions
    Unit Group - Pick every unit in chaospherecastinggroup and do (Actions)
      Loop - Actions
        Set VariableSet chaospherepickedunit = (Picked unit)
        Unit Group - Pick every unit in (Load 10 of (Key (Picked unit).) in chaospherehashtable.) and do (Actions)
          Loop - Actions
            If (All Conditions are True) then do (Then Actions) else do (Else Actions)
              If - Conditions
                (Random integer number between 1 and 15) Equal to 1
              Then - Actions
                -------- Creating Dummy --------
                Set VariableSet temppoint = (Position of (Picked unit))
                Set VariableSet temppoint2 = (Point((Load 13 of (Key chaospherepickedunit.) from chaospherehashtable.), (Load 14 of (Key chaospherepickedunit.) from chaospherehashtable.)))
                -------- IMPORTING: Next Event should read: "Unit - Create 1 Dummy for..." --------
                Unit - Create 1.Dummy for (Load 11 of (Key chaospherepickedunit.) in chaospherehashtable.) at temppoint facing 270.00 degrees
                Unit - Add a 3.00 second Generic expiration timer to (Last created unit)
                -------- Casting a Random Spell --------
                Set VariableSet tempreal = (Random real number between 0.01 and chaospheretotalchance)
                If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                  If - Conditions
                    tempreal Greater than chaospherechance[0]
                    tempreal Less than or equal to chaospherechance[1]
                  Then - Actions
                    Set VariableSet temppoint3 = (temppoint2 offset by ((Random real number between 7.00 and 20.00) x (Random real number between 7.00 and 20.00)) towards (Random angle) degrees.)
                    Special Effect - Create a special effect at temppoint using Abilities\Spells\NightElf\Blink\BlinkTarget.mdl
                    Special Effect - Destroy (Last created special effect)
                    Special Effect - Create a special effect at temppoint3 using Abilities\Spells\NightElf\Blink\BlinkCaster.mdl
                    Special Effect - Destroy (Last created special effect)
                    Unit - Move (Picked unit) instantly to temppoint3
                    Custom script: call RemoveLocation (udg_temppoint3)
                  Else - Actions
                If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                  If - Conditions
                    tempreal Greater than chaospherechance[1]
                    tempreal Less than or equal to chaospherechance[2]
                  Then - Actions
                    Special Effect - Create a special effect attached to the origin (attachpoint) of (Picked unit) using Abilities\Spells\Items\AIil\AIilTarget.mdl
                    Special Effect - Destroy (Last created special effect)
                    Set VariableSet tempugroup = (Units within 300.00 of temppoint matching (((Matching unit) Not equal to (Picked unit)) and (((Matching unit) belongs to an ally of (Owner of (Picked unit)).) Equal to True)).)
                    Unit - Order (Picked unit) to Attack.(Random unit from tempugroup)
                    Custom script: call DestroyGroup (udg_tempugroup)
                  Else - Actions
                If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                  If - Conditions
                    tempreal Greater than chaospherechance[2]
                    tempreal Less than or equal to chaospherechance[3]
                  Then - Actions
                    -------- IMPORTING: Next Event should read: "Unit - Add Voodoo Curse (Dummy)..." --------
                    Unit - Add Voodoo Curse (Dummy) to (Last created unit)
                    Unit - Order (Last created unit) to Night Elf Druid Of The Talon - Faerie Fire.(Picked unit)
                  Else - Actions
                If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                  If - Conditions
                    tempreal Greater than chaospherechance[3]
                    tempreal Less than or equal to chaospherechance[4]
                  Then - Actions
                    -------- IMPORTING: Next Event should read: "Unit - Add Blind (Dummy)..." --------
                    Unit - Add Blind (Dummy) to (Last created unit)
                    Unit - Order (Last created unit) to Undead Banshee - Curse.(Picked unit)
                  Else - Actions
                If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                  If - Conditions
                    tempreal Greater than chaospherechance[4]
                    tempreal Less than or equal to chaospherechance[5]
                  Then - Actions
                    -------- IMPORTING: Next Event should read: "Unit - Add Shadow Strike (Dummy)..." --------
                    Unit - Add Shadow Strike (Dummy) to (Last created unit)
                    Unit - Order (Last created unit) to Undead Necromancer - Unholy Frenzy.(Picked unit)
                  Else - Actions
                If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                  If - Conditions
                    tempreal Greater than chaospherechance[5]
                    tempreal Less than or equal to chaospherechance[6]
                  Then - Actions
                    -------- IMPORTING: Next Event should read: "Unit - Add Shock (Dummy)..." --------
                    Unit - Add Shock (Dummy) to (Last created unit)
                    Unit - Order (Last created unit) to Orc Far Seer - Chain Lightning.(Picked unit)
                  Else - Actions
                If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                  If - Conditions
                    tempreal Greater than chaospherechance[6]
                    tempreal Less than or equal to chaospherechance[7]
                  Then - Actions
                    -------- IMPORTING: Next Event should read: "Unit - Add Slow (Dummy)..." --------
                    Unit - Add Slow (Dummy) to (Last created unit)
                    Unit - Order (Last created unit) to Human Sorceress - Slow.(Picked unit)
                  Else - Actions
                If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                  If - Conditions
                    tempreal Greater than chaospherechance[7]
                    tempreal Less than or equal to chaospherechance[8]
                  Then - Actions
                    -------- IMPORTING: Next Event should read: "Unit - Add Silence (Dummy)..." --------
                    Unit - Add Silence (Dummy) to (Last created unit)
                    Unit - Order (Last created unit) to Neutral Pit Lord - Doom.(Picked unit)
                  Else - Actions
                If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                  If - Conditions
                    tempreal Greater than chaospherechance[8]
                    tempreal Less than or equal to chaospherechance[9]
                  Then - Actions
                    -------- IMPORTING: Next Event should read: "Unit - Sleep (Dummy)..." --------
                    Unit - Add Sleep (Dummy) to (Last created unit)
                    Unit - Order (Last created unit) to Undead Dreadlord - Sleep.(Picked unit)
                  Else - Actions
                If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                  If - Conditions
                    tempreal Greater than chaospherechance[9]
                    tempreal Less than or equal to chaospherechance[10]
                  Then - Actions
                    -------- IMPORTING: Next Event should read: "Unit - Add Hex (Dummy)..." --------
                    Unit - Add Hex (Dummy) to (Last created unit)
                    Unit - Order (Last created unit) to Orc Shadow Hunter - Hex.(Picked unit)
                  Else - Actions
                Custom script: call RemoveLocation (udg_temppoint)
                Custom script: call RemoveLocation (udg_temppoint2)
              Else - Actions

LIST OF CURRENT BUFFS/EFFECTS


- Blind - Causes the target to miss on 33% of their attacks. Lasts 20 (10) seconds.
- Confusion - Causes the target to attack a random nearby allied unit.
- Hex - Turns the target into a random critter. Lasts 10 (3) seconds.
- Poison - Deals 5 damage per second. Lasts 16 (8) seconds.
- Shock - Damages target for 50 damage.
- Silence - Prevents target from using spells. Lasts 12 (4) seconds.
- Sleep - Stuns target, is awoken if damaged. Lasts 8 (4) seconds.
- Slow - Slows the target's attack speed by 25% and move speed by 60%. Lasts 16 (8) seconds.
- Voodoo Curse - Reduces the target's armor by 3 and provides vision. Last 20 (10) seconds.
- Warp - Teleports the target to random location inisde the sphere.



OTHER DATA


Area of Effect = 500.0
Duration = 20.0 seconds (with a 2.0 seconds startup time, non interruptable)
Average Buff Interval = 3.0 seconds

ADDING A NEW BUFF/EFFECT



TO ADD A NEW BUFF/EFFECT

(skip step 1 if your effect contains no dummy spell)
1) Create a dummy spell in the object editor ensure that: the spell:
- Is not channeling or has a long cast time
- Targets a single unit
- Has a cost of 0 mana
- Does not have a techtree requirement
- Has the correct targets enabled
- Has a suitable buff

2) Open the Variables Panel (Ctrl+B)
- Edit the Variable "chaospherechance"
Replace the array size - 10 with the new total number of buffs/effects

3) Go to the 'Chaosphere Init' trigger
- Change this line:
"Set chaospherenumbereffects = 10"
Replace the 10 with the new total number of buffs/effects
- Add a new line:
"chaospherechance[n] = x.xx"
Set n to this buff's corresponding number
Set x.xx to the chance of this buff occuring
- You may wish to play with the numbers so that they still add up to 100.00

3) Go to the 'Chaosphere Effect' trigger
- Add your new effect to the list, for example:
If - Conditions
tempreal Greater than chaospherechance[10]
tempreal Less than or equal to chaospherechance[11]
Then - Actions
Unit - Add Mana Burn (Dummy) to (Last created unit)
Unit - Order (Last created unit) to Night Elf Demon Hunter - Mana Burn (Picked unit)
Else - Actions





HOW TO IMPORT


Unfortunately, due to the nature of this spell, it can be difficult to import. However this is how I would recommend that you did it:

1) Copy the two buffs to your map;
- Blind
- Voodoo Curse

2) Copy the 6 dummy spells to your map:
- Silence (Dummy)
- Blind (Dummy)
- Hex (Dummy)
- Shadow Strike (Dummy)
- Shock (Dummy)
- Sleep (Dummy)
- Slow (Dummy)
- Voodoo Curse (Dummy)

3) Check that the following dummy spells are using the correct buffs:
- Blind (Dummy)
- Voodoo Curse (Dummy)

4) Copy the main spell to your map; Chaosphere.

5) Export the 3 textures and model from the map into a folder. (Models and textures by Darky29)
And re-import them into your new map. Set the textures to the corresponding paths:
- AuraRune11.blp >>> Anims\ShieldSpell\AuraRune11.blp
- AuraRune11b.blp >>> Anims\ShieldSpell\AuraRune11b.blp
- TrollSymbol1.blp >>> Anims\ShieldSpell\TrollSymbol1.blp

6) Copy the 3 dummy units to your map:
- Chaosorb
- Chaosphere
- Dummy

7) Ensure that the "Automatically create unknown variables while pasting trigger data" option is ticked.
This is under File -> Preferences -> General

8) Copy the Trigger Folder "Chaosphere Spell" to your map.

9) Check that all references to units and spells in the triggering read correctly.
These are pointed out in the trigger comments at the top and throughout the triggering, and are labelled with "IMPORTING:"

10) Add the spell to a unit or hero in your map.
Sets Up Creeps and Visibility.
Testing Init
  Events
    Map initialization
  Conditions
  Actions
    Visibility - Disable fog of war
    Visibility - Disable black mask
    Hero - Disable experience gain for Archmage 0033 <gen>.
    Player - Turn Gives bounty Off for Neutral Hostile
Revives Heroes and Creeps.
Testing Revive
  Events
    Unit - A unit Dies
  Conditions
  Actions
    If (All Conditions are True) then do (Then Actions) else do (Else Actions)
      If - Conditions
        (Unit-type of (Triggering unit)) Equal to Footman
      Then - Actions
        Wait 20.00 seconds
        Unit - Create 1.Footman for Neutral Hostile at (Center of Region_000 <gen>) facing (Random angle) degrees
      Else - Actions
    If (All Conditions are True) then do (Then Actions) else do (Else Actions)
      If - Conditions
        (Unit-type of (Triggering unit)) Equal to Archmage
      Then - Actions
        Wait 30.00 seconds
        Hero - Instantly revive (Triggering unit) at (Center of Region_000 <gen>), Show revival graphics
      Else - Actions
    If (All Conditions are True) then do (Then Actions) else do (Else Actions)
      If - Conditions
        (Unit-type of (Triggering unit)) Equal to Hexmaster
      Then - Actions
        Wait 2.00 seconds
        Hero - Instantly revive (Triggering unit) at ((Owner of (Triggering unit)) start location), Show revival graphics
      Else - Actions