HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

Firebars & Explody things

02-17-2010, 06:25 PM#1
Sunwarrior25
Basically, how can I do these better?
  1. I'm trying to get Mario-esque fire bars in the small portion of the two-team dungeon leading up to the first mid-boss that isn't just a Hero-type unit. While they do indeed work, I have a feeling that they are quite laggy in their execution.
  2. You know those awesome goblin machines that were submitted recently? Well, I got the idea to have the pilots eject from their fire machines, and reappear in a flying chair. Not sure if I did it right.
  3. The trigger that handles both. SplodyTMR is started in the ZeroSeconds trigger (not shown here).
    Hidden information:
    Trigger:
    Collapse SetupLazerArrayz
    Events
    Conditions
    Collapse Actions
    Set LazerGuy[0] = Fire Bar 0007 <gen>
    Set LazerLength[0] = 5
    Set LazerDir[0] = 5
    Set LazerAngle[0] = 0.00
    Set LazerGuy[1] = Fire Bar 0010 <gen>
    Set LazerLength[1] = 5
    Set LazerDir[1] = 5
    Set LazerAngle[1] = 180.00
    Set LazerGuy[2] = Fire Bar 0152 <gen>
    Set LazerLength[2] = 4
    Set LazerDir[2] = -5
    Set LazerAngle[2] = 0.00
    Set LazerGuy[3] = Fire Bar 0016 <gen>
    Set LazerLength[3] = 4
    Set LazerDir[3] = -5
    Set LazerAngle[3] = 180.00
    Set LazerGuy[4] = Fire Bar 0011 <gen>
    Set LazerLength[4] = 5
    Set LazerDir[4] = 5
    Set LazerAngle[4] = 0.00
    Set LazerGuy[5] = Fire Bar 0021 <gen>
    Set LazerLength[5] = 5
    Set LazerDir[5] = 5
    Set LazerAngle[5] = 180.00
    Set LazerAmt = 5
    Collapse For each (Integer A) from 0 to LazerAmt, do (Actions)
    Collapse Loop - Actions
    Collapse For each (Integer B) from 0 to LazerLength[(Integer A)], do (Actions)
    Collapse Loop - Actions
    Unit - Create 1 Fire Ball for (Owner of LazerGuy[(Integer A)]) at ((Position of LazerGuy[(Integer A)]) offset by (128.00 + (64.00 x (Real((Integer B))))) towards 0.00 degrees) facing Default building facing degrees
    Unit Group - Add (Last created unit) to LazerGrup[(Integer A)]
    Collapse Escapeh
    Collapse Events
    Unit - A unit Is attacked
    Collapse Conditions
    ((Attacked unit) is paused) Equal to False
    (Unit-type of (Attacked unit)) Equal to Goblin Fire Machine
    (Life of (Attacked unit)) Less than or equal to 150.00
    ((Attacked unit) is dead) Equal to False
    Collapse Actions
    Unit - Pause (Attacked unit)
    Animation - Play (Attacked unit)'s morph animation
    Animation - Add the alternate animation tag to (Attacked unit)
    Animation - Queue (Attacked unit)'s stand alternate animation
    Unit - Create 1 Flying Chair for (Owner of (Attacked unit)) at (Position of (Attacked unit)) facing (Facing of (Attacked unit)) degrees
    Animation - Play (Last created unit)'s birth animation
    Animation - Queue (Last created unit)'s stand animation
    Unit Group - Add (Attacked unit) to SplodyGrup
    Special Effect - Create a special effect attached to the chest of (Attacked unit) using war3mapImported\SmokefireColumn.mdx
    Collapse Splosions
    Collapse Events
    Time - SplodyTMR expires
    Conditions
    Collapse Actions
    Collapse Unit Group - Pick every unit in SplodyGrup and do (Actions)
    Collapse Loop - Actions
    Unit - Set life of (Picked unit) to ((Life of (Picked unit)) - 1.00)
    Collapse If (All Conditions are True) then do (Then Actions) else do (Else Actions)
    Collapse If - Conditions
    (Life of (Picked unit)) Less than or equal to 10.00
    Collapse Then - Actions
    Unit - Cause (Picked unit) to damage circular area after 0.00 seconds of radius 256.00 at (Position of (Picked unit)), dealing 100.00 damage of attack type Siege and damage type Fire
    Unit - Cause (Picked unit) to damage circular area after 0.00 seconds of radius 128.00 at (Position of (Picked unit)), dealing 100.00 damage of attack type Siege and damage type Fire
    Unit - Cause (Picked unit) to damage circular area after 0.00 seconds of radius 64.00 at (Position of (Picked unit)), dealing 100.00 damage of attack type Siege and damage type Fire
    Special Effect - Create a special effect at (Position of (Picked unit)) using war3mapImported\ExplosionBIG.mdx
    Special Effect - Destroy (Last created special effect)
    Unit Group - Remove (Picked unit) from SplodyGrup
    Else - Actions
    Collapse For each (Integer A) from 0 to LazerAmt, do (Actions)
    Collapse Loop - Actions
    Set LazerAngle[(Integer A)] = (LazerAngle[(Integer A)] - (Real(LazerDir[(Integer A)])))
    Collapse Unit Group - Pick every unit in LazerGrup[(Integer A)] and do (Actions)
    Collapse Loop - Actions
    Unit - Move (Picked unit) instantly to ((Position of LazerGuy[(Integer A)]) offset by (Distance between (Position of LazerGuy[(Integer A)]) and (Position of (Picked unit))) towards LazerAngle[(Integer A)] degrees)
    Animation - Change (Picked unit) flying height to 30.00 at 0.00
    Unit - Cause (Picked unit) to damage circular area after 0.00 seconds of radius 64.00 at (Position of (Picked unit)), dealing 100.00 damage of attack type Spells and damage type Fire
    Unit - Set life of (Picked unit) to 100.00%
    Unit - Set life of LazerGuy[(Integer A)] to 100.00%