How to increase Unit Damage using Trigger?

Status
Not open for further replies.
Level 3
Joined
Apr 5, 2016
Messages
21
So after i know how to make stacked ability, now i want to know how to increase Unit Damage using trigger, Example: (Increase the unit damage by (Total Str x 5))
 

EdgeOfChaos

E

EdgeOfChaos

Give the unit inventory, give them tomes with the ability "Item Permanent Damage Gain" until they have the damage you want them to have.
There may be better ways but this works.
 

Dr Super Good

Spell Reviewer
Level 64
Joined
Jan 18, 2005
Messages
27,285
Give the unit inventory, give them tomes with the ability "Item Permanent Damage Gain" until they have the damage you want them to have.
Remember to remove the tome items after they are used otherwise they will leak. Consume on pickup items die and never decay.

If you want green bonus numbers then use a bonus mod system which is basically a series of power of 2 value item damage abilities that get added/removed from a unit.
 
Last edited:

Dr Super Good

Spell Reviewer
Level 64
Joined
Jan 18, 2005
Messages
27,285
If a unit drops a tome, does it leak?
This question is unclear. RoC style tomes that are consumed as items in inventory do not leak as they get removed like all consumable items get removed once all charges are depleted. If a unit was to drop such an item and kill it with combat damage then it will leak as items never get automatically removed when killed.

If a trigger is used to create a tome item in response to a unit dying, eg how a melee creep can drop a tome on death, and that tome is a TFT style tome and is used by a hero then it leaks. Consume on pickup kills the item and dead items do not get automatically removed.

The solution is to remove the item using triggers at the end of its useful life. For a tome this will be after the tome is used as one cannot ever re-use the same tome item.
 
Last edited:
Level 11
Joined
Nov 25, 2014
Messages
526
So I have a trigger that a unit will drop a random tome when it is killed, so what dyou mean by removing the timer using triggers at the end of its useful life? How should I do it?

Sorry for posting another question in this thread
 
Level 16
Joined
Mar 25, 2016
Messages
1,327
It's not a leak that comes from triggers, but it's just there whenever a tome is used.

To fix it you can use:
  • RemoveTomes
    • Events
      • Unit - A unit Acquires an item
    • Conditions
      • (Item-class of (Item being manipulated)) Equal to Powerup
    • Actions
      • Item - Remove (Item being manipulated)
I would rather wait a little bit before removing, so the death animation of the tome can play. In your case you only want to use tomes to increase damage, so I don't think you need a death animation.
 
Status
Not open for further replies.
Top