How to create Triggered Spell Damage Over Time(DOT)?

NightFelix

Active Member
Reaction score
1
Tittle. I have search around the forum and I found that some people mention using Acid Bomb. But is it possible to create a Spell that have Damage Over Time by using trigger?

Because I want to create a Damage Over Time spell that based on Hero attributes. Such like: Hurt 100 initial damage on the target and deal 3x STR damage over time to the target for 10sec.

And one more reason if I really do using the Acid Bomb to make the spell. How do I make the A Hero having the acid bomb and B Hero having another acid bomb and attack on the same target C Creep to make both acid bomb non-stack deal damage.
 

AgentPaper

From the depths, I come.
Reaction score
107
Have a trigger run every X seconds, where X is the time between "ticks" of damage. Have it find every unit with the Effect that your ability gives for the duration, and have to do whatever periodic damage you want it to do.

If you have a whole lot of units, you could also make the game store each unit currently under the effects in a unit array, and also store how many "ticks" of the spell each of those units has in a parallel array. To keep it from stacking, have the trigger check through the array to see if the unit being affected is already on the list, and if it is, simply set the "ticks left" variable to be whatever the initial value is.
 

Angel_Island

Much long, many time, wow
Reaction score
56
Try use this:
Trigger:
  • Untitled Trigger 003
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to Acid Bomb
    • Actions
      • Set Caster = (Triggering unit)

Trigger:
  • Untitled Trigger 002
    • Events
      • Time - Every 1.00 seconds of game time
    • Conditions
    • Actions
      • Set Group = (Units in (Playable map area) matching (((Matching unit) has buff Acid Bomb) Equal to True))
      • Unit Group - Pick every unit in Group and do (Actions)
        • Loop - Actions
          • Unit - Cause Caster to damage (Picked unit), dealing (100.00 + ((Real((Strength of Caster (Include bonuses)))) x 3.00)) damage of attack type Hero and damage type Universal
    • Custom script: call DestroyGroup(udg_Group)
 

NightFelix

Active Member
Reaction score
1
Can I use wait 1sec of game time and deal damage and wait 1sec again and deal damage and 1sec again and again....?
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Members online

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top