• 🏆 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!

Need help with rage (type of mana usage)

Status
Not open for further replies.
Level 1
Joined
Mar 16, 2008
Messages
1
For those of you who don't already know, rage is a type of "mana" where you gain it when you attack and when you are getting attacked. It caps at 100. When you are not in combat, it slowly fades.

I am making a hero map with a druid (similar to the druid from WoW) as one of the heroes. Cat form uses energy, and bear form uses rage. I've already triggered it so that you gain rage when dealing damage and when taking damage, and I've triggered it so that no matter how much your max mana is, you will not gain any mana (energy/rage) once you get over 100, so your mana could say 100/145, but you will not get any more mana, regardless of what happens.

So my question is: How do I make it so rage starts fading when my bear druid isn't in combat? Let's say you leave combat after 5 seconds of not attacking/being attacked. I made a trigger that takes 7 mana away from the unit every 5 seconds, and when he attacks or gets attacked, the trigger is turned off. How do I get the trigger turned back on after 5 seconds of no attacking?

Thanks.
 
Level 13
Joined
Jul 3, 2008
Messages
1,098
event:
unit has attacked unit
condition:
tipe of attacking unit equal to your unit
or
tipe of attacked unit equal to your unit
action:
your actions
wait 5 seconds
cheking conditions
unit tipe of your unit is not attaking
or
unit tipe of your unit is not attacked
then:
turn on trigger 2

trigger 2 is your trigger to remove mana out of combat
i hope it will work
 
Level 2
Joined
Aug 24, 2008
Messages
16
-Events-
A unit finishes training a unit
-Conditions-
Trained unit equals to <Rage Hero>
-Actions-
Set <Variable(Unit)> equal to <Trained Unit>
Turn On <Next Trigger>

-Events-
Every 1.00 Seconds
-Conditions-
Skipped
-Actions-
Set Mana Of <Variable(Unit)> Equal To [(Mana Of <Variable(Unit)>)-2(Exp)

Then, Edit The Rage Given Wen The Hero Is Attacked Or Attacks By 2.
So Constantly, Rage Wil Be Deducted Bt In Battle It Wil Nt Affect The Rage Given.
 
Status
Not open for further replies.
Top