• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

[Trigger] Evasion-Like Ability

Status
Not open for further replies.
Level 1
Joined
Dec 30, 2008
Messages
5
Ive been trying to make a simple trigger..I basicly want it so when theres a set percent chance that when a unit is attacked he takes no damage while automatically phases around the opponent..I have the main part done, but when the unit gets hit he still takes damage..so i need to find a way to heal the unit the damage the opponent dealt..i tried Event Response - Damage Taken..but that dident work unfortunely..i was hopeing someone could help..heres what i got so far..
  • Phase Shift
    • Events
      • Unit - A unit Is attacked
    • Conditions
      • (Unit-type of (Attacked unit)) Equal to Test Defender
    • Actions
      • Set Phase_Integer = (Random integer number between 1 and 10)
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • Or - Any (Conditions) are true
            • Conditions
              • Phase_Integer Equal to 1
              • Phase_Integer Equal to 2
              • Phase_Integer Equal to 3
              • Phase_Integer Equal to 4
        • Then - Actions
          • Unit - Remove Evasion from (Attacked unit)
          • Unit - Add Phase Shift to (Attacked unit)
          • Unit - Order (Attacked unit) to Night Elf Faerie Dragon - Phase Shift
          • Wait 0.50 seconds
          • Unit - Move (Attacked unit) instantly to ((Position of (Attacking unit)) offset by -200.00 towards (Facing of (Attacking unit)) degrees), facing (Position of (Attacking unit))
          • Wait 0.25 seconds
          • Unit - Order (Attacked unit) to Attack (Attacking unit)
          • Unit - Remove Phase Shift from (Attacked unit)
          • Unit - Add Evasion to (Attacked unit)
        • Else - Actions
The Unit - Add/Remove Evasion..are only for looks for the hero..

Thanks in advance ;x
 
Status
Not open for further replies.
Top