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

Specific spell filter in the Damage Engine System

Status
Not open for further replies.
Level 4
Joined
Dec 17, 2020
Messages
28
Hello everyone, thanks for the great work you do.

I have a question about the use of "Damage Engine System". How can I filter the damage of specific spells and put them as a condition for the final damage result?

For example, 2 warstomp based spells, one has fire graphics and the other shadows, depending on what items the hero is carrying, the damage can be increased from one or the other warstomp. Same for many other spells.
 

Uncle

Warcraft Moderator
Level 64
Joined
Aug 10, 2018
Messages
6,555
If you're on 1.31+ you don't need to use a Damage Engine for this. You can modify abilities using the Set Ability Integer/Real/Boolean actions.

Otherwise, you can use a variable to mark that your next damage instance is going to be from your desired ability:
  • Events
  • Unit - A unit starts the effect of an ability
  • Conditions
  • (Ability being cast) Equal to Warstomp Fire
  • Actions
  • Set Variable WarstompFireDamage = True

Now in your DamageEvent trigger you can check if WarstompFireDamage is True, and if it is, do whatever you need to do. Then Set it back to False. For MUI purposes you could do this using a Unit Indexer / Hashtable.
 
Last edited:
Status
Not open for further replies.
Top