Tracking how much damage a unit gets

Hildagarn

Member
Reaction score
20
One of the heroes in my game has an ability which increases his attack (which is just a modified roar) and during the duration of the ability, any attack made on him will award him points (lumber). I can't seem to find out how to get the damage.

Also, is there an ability that increases defense by a percentage?
 

millzy

Ultra Cool Member
Reaction score
44
here this might work im not sure but give it a try
Trigger:
  • Runing Damage Triger
    • Events
      • Time - Every 6.60 seconds of game time
    • Conditions
    • Actions
      • Set MapGroup = (Units owned by YOUR enemy matching (((Matching unit) is alive) Equal to True))
      • Unit Group - Pick every unit in MapGroup and do (Actions)
        • Loop - Actions
          • Trigger - Add to Damage Triger <gen> the event (Unit - (Picked unit) Takes damage)
      • Custom script: call DestroyGroup(udg_MapGroup)


Trigger:
  • Damage Triger
    • Events
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Damage taken) Not equal to 0.00
        • Then - Actions
          • Player - Add (Integer((Damage taken))) to (Owner of (Attacking unit)) Current lumber
        • Else - Actions


you might want to add a condition that attacking unit has buff


i dont know of any abilitys that give armour by a percentage
 

avalya

New Member
Reaction score
37
Unless devotion aura can be set to a percentage, then I doubt there are any percent-based defense increases.
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Members online

      No members online now.

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top