• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

Life/Speed Trigger doesnt work

Status
Not open for further replies.
Level 7
Joined
Apr 13, 2012
Messages
110
My beautifull Life/Speed Triggers doesnt work

  • lifeisup
    • Events
      • Time - Every 0.01 seconds of game time
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Life of THEUNIT) Greater than ((Max life of THEUNIT) / 2.00)
        • Then - Actions
          • Set unitspeed = (Current movement speed of THEUNIT)
        • Else - Actions
  • lifeisdown
    • Events
      • Time - Every 0.01 seconds of game time
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Life of THEUNIT) Less than or equal to ((Max life of THEUNIT) / 2.00)
          • (Life of THEUNIT) Greater than ((Max life of THEUNIT) / 2.50)
        • Then - Actions
          • Trigger - Turn off lifeisup <gen>
          • Unit - Set THEUNIT movement speed to (unitspeed / 1.15)
          • Unit - Set mana of THEUNIT to ((Mana of THEUNIT) / 1.50)
          • Trigger - Turn on lifeisupagain <gen>
          • Trigger - Turn off (This trigger)
        • Else - Actions
  • lifeisdownless
    • Events
      • Time - Every 0.01 seconds of game time
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Life of THEUNIT) Less than or equal to ((Max life of THEUNIT) / 2.50)
          • (Life of THEUNIT) Greater than ((Max life of THEUNIT) / 3.00)
        • Then - Actions
          • Trigger - Turn off lifeisup <gen>
          • Unit - Set THEUNIT movement speed to (unitspeed / 1.20)
          • Unit - Set mana of THEUNIT to ((Mana of THEUNIT) / 1.50)
          • Trigger - Turn on lifeisupagain <gen>
          • Trigger - Turn off (This trigger)
        • Else - Actions
  • lifeisupagain
    • Events
      • Time - Every 0.01 seconds of game time
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Life of THEUNIT) Greater than ((Max life of THEUNIT) / 2.00)
        • Then - Actions
          • Unit - Set THEUNIT movement speed to unitspeed
          • Trigger - Turn on lifeisup <gen>
          • Trigger - Turn on lifeisdown <gen>
          • Trigger - Turn on lifeisdownless <gen>
          • Trigger - Turn off (This trigger)
        • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Life of THEUNIT) Less than or equal to ((Max life of THEUNIT) / 2.00)
        • Then - Actions
          • Trigger - Turn on lifeisdown <gen>
          • Trigger - Turn on lifeisdownless <gen>
          • Trigger - Turn off (This trigger)
        • Else - Actions
So when current life is under maxlife/2 is desreased
when current life is under maxlife/2.5 is desreased more..

It was working fine until at one test it fails
i cant fix it i ll keep trying.. feedback welcomed..
 
Status
Not open for further replies.
Top