Rage

The_Reaping

Member
Reaction score
2
Okay, so my ability rage is a passive ability that whenever my hero kills a unit, he recieves a rage counter that increases his damage and attack speed by a small amount but can stack up to 5 times. Each counter lasts 10 seconds, but if the hero kills another enemy before the timer expires, the timer resets and the rage counter increases.

My problem: I don't know how to reset the timer after he kills another unit.. :/

The trigger I have at the moment is.

Trigger:
  • Rage Counters
    • Events
      • Unit - A unit Dies
    • Conditions
      • (Unit-type of (Killing unit)) Equal to Rage Demon
    • Actions
      • Set Caster = (Killing unit)
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • ((Dying unit) belongs to an enemy of (Owner of Caster)) Equal to True
        • Then - Actions
          • Set RageCounter = (RageCounter + 1)
          • Floating Text - Create floating text that reads (String(RageCounter)) at (Position of Caster) with Z offset 90.00, using font size 15.00, color (0.00%, 100.00%, 0.00%), and 0.00% transparency
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • (Level of Rage for Caster) Equal to 1
            • Then - Actions
              • Unit - Add Rage Attack Speed (Level 1) to Caster
              • Unit - Add Rage Damage (Level 1) to Caster
              • Unit - Set level of Rage Attack Speed (Level 1) for Caster to RageCounter
              • Unit - Set level of Rage Damage (Level 1) for Caster to RageCounter
            • Else - Actions
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • (Level of Rage for Caster) Equal to 2
                • Then - Actions
                  • Unit - Add Rage Attack Speed (Level 2) to Caster
                  • Unit - Add Rage Damage (Level 2) to Caster
                  • Unit - Set level of Rage Attack Speed (Level 2) for Caster to RageCounter
                  • Unit - Set level of Rage Damage (Level 2) for Caster to RageCounter
                • Else - Actions
                  • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                    • If - Conditions
                      • (Level of Rage for Caster) Equal to 3
                    • Then - Actions
                      • Unit - Add Rage Attack Speed (Level 3) to Caster
                      • Unit - Add Rage Damage (Level 3) to Caster
                      • Unit - Set level of Rage Attack Speed (Level 3) for Caster to RageCounter
                      • Unit - Set level of Rage Damage (Level 3) for Caster to RageCounter
                    • Else - Actions
                      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                        • If - Conditions
                          • (Level of Rage for Caster) Equal to 4
                        • Then - Actions
                          • Unit - Add Rage Attack Speed (Level 4) to Caster
                          • Unit - Add Rage Damage (Level 4) to Caster
                          • Unit - Set level of Rage Attack Speed (Level 4) for Caster to RageCounter
                          • Unit - Set level of Rage Damage (Level 4) for Caster to RageCounter
                        • Else - Actions
        • Else - Actions
      • Countdown Timer - Start RageTimer as a One-shot timer that will expire in 10.00 seconds


Thanks :D
 
Err not sure.. But that's not the bit i'm having trouble with :/ It's the checking to see if the hero kills another unit during the 10 seconds that I don't know how to do.

Well you don't need to check, because you have a trigger that already checks when a unit is killed! Just add some actions at the end of your trigger to reset the timer and then restart it for 10 seconds.
 
Just a short note, if you set your abilities to ability arrays, you can jsut simple do

For each integer A do:
If level of rage caster equal to integer A
Then give the abilities[integer A]
 
General chit-chat
Help Users

      The Helper Discord

      Staff online

      Members online

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top