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

Need help with an ability to work like this if it's possible...

Status
Not open for further replies.
Level 14
Joined
Jul 19, 2007
Messages
772
I need an ability for my map that is based on "Battle Roar" but instead of giving bonus attack damage I want it to reduce the damage taken from ranged attacks for all units with the buff. I have no idéa how to make this or if it's possible but I want it to have 4 levels and reduce the ranged damage taken by 25/35/45/55%. Please help me to make this ability if it's possible...
 
Level 14
Joined
Jul 19, 2007
Messages
772
Easily done with DDS, I recommend Bribe's.
Fiddle with the test map and you can easily find what you need.
No I can't do this myself because I'm so noobish at triggering and someone already imported a "Damage Engine" system to my map when he helped me to create another spell but I don't remember who made it to me... If you have 2 "Damage Engine" systems in your map, they can make the whole map crash, right?
 
Level 24
Joined
Feb 9, 2009
Messages
1,787
What damage engine was it?
upload_2020-8-21_11-53-12.png
 
Level 14
Joined
Jul 19, 2007
Messages
772
What damage engine was it?
View attachment 362455
  • Damage Engine
    • Events
      • Game - UnitIndexEvent becomes Equal to 1.00
      • Game - UnitIndexEvent becomes Equal to 2.00
    • Conditions
    • Actions
      • -------- Copy the Cheat Death Ability from Object Editor into your map and set the following variable respectively: --------
      • Set VariableSet DamageBlockingAbility = Avatar (Neutral)
      • -------- - --------
      • Set VariableSet DamageTypeSpell = 1
      • Set VariableSet DamageTypeDOT = 2
      • Set VariableSet DamageTypeRanged = 3
      • -------- - --------
      • Custom script: call ExecuteFunc("InitDamageEvent")
      • Custom script: endfunction
      • Custom script:
      • Custom script: function DmgEvFilter takes nothing returns boolean
      • -------- - --------
      • -------- The next conditions let you filter out unwanted units. By default, units with Locust will not pass the check. --------
      • -------- - --------
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (TempUnit is A structure) Equal to False
        • Then - Actions
          • Custom script: return true
        • Else - Actions
      • Custom script: return false
      • Custom script: endfunction
      • Custom script:
      • Custom script: function DmgEvRemoveAbilities takes nothing returns nothing
      • Custom script: local real r
      • Custom script: loop
      • Set VariableSet DmgEvN = (DmgEvN - 1)
      • Custom script: set r = GetWidgetLife(udg_DmgEvStack[udg_DmgEvN])
      • Unit - Remove DamageBlockingAbility from DmgEvStack[DmgEvN]
      • Custom script: call SetWidgetLife(udg_DmgEvStack[udg_DmgEvN], r)
      • Set VariableSet DmgEvStack[DmgEvN] = No unit
      • Custom script: exitwhen udg_DmgEvN == 0
      • Custom script: endloop
      • Custom script: endfunction
      • Custom script:
      • Custom script: function DmgEvSetVars takes nothing returns nothing
      • Set VariableSet DamageEventAmount = (Damage taken)
      • Set VariableSet DamageEventSource = (Damage source)
      • Set VariableSet DamageEventTarget = (Triggering unit)
      • Custom script: endfunction
      • Custom script:
      • Custom script: function FireDmgEv takes nothing returns nothing
      • Custom script: local boolean b = GetUnitAbilityLevel(udg_DamageEventTarget, udg_DamageBlockingAbility) > 0
      • Custom script: local real life = 0
      • Custom script: local real pain = 0
      • Custom script: if b then
      • Custom script: set life = GetWidgetLife(udg_DamageEventTarget)
      • Unit - Remove DamageBlockingAbility from DamageEventTarget
      • Custom script: call SetWidgetLife(udg_DamageEventTarget, life)
      • Custom script: set pain = GetWidgetLife(udg_DamageEventTarget)
      • Custom script: endif
      • Set VariableSet DamageEventPrevAmt = DamageEventAmount
      • Set VariableSet DamageEventExplodesUnit = False
      • Set VariableSet DamageEventOverride = False
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • DamageEventAmount Equal to 0.00
        • Then - Actions
          • Set VariableSet DamageEvent = 2.00
        • Else - Actions
          • Set VariableSet DamageModifierEvent = 1.00
          • Set VariableSet DamageEvent = 1.00
      • Custom script: if b then
      • Unit - Add DamageBlockingAbility to DamageEventTarget
      • Custom script: call SetWidgetLife(udg_DamageEventTarget, life + GetWidgetLife(udg_DamageEventTarget) - pain)
      • Custom script: endif
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • DamageEventAmount Not equal to DamageEventPrevAmt
        • Then - Actions
          • Set VariableSet DmgEvLife = ((Life of DamageEventTarget) + (DamageEventPrevAmt - DamageEventAmount))
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • DamageEventAmount Greater than DamageEventPrevAmt
            • Then - Actions
              • Unit - Set life of DamageEventTarget to (Max(0.41, DmgEvLife))
              • Custom script: if udg_DmgEvLife <= .405 then
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • DamageEventExplodesUnit Equal to True
                • Then - Actions
                  • Unit - Make DamageEventTarget Explode on death
                • Else - Actions
              • Trigger - Turn off DamageEventTrigger
              • Custom script: call UnitDamageTarget(udg_DamageEventSource, udg_DamageEventTarget, 999, false, false, null, null, null)
              • Trigger - Turn on DamageEventTrigger
              • Custom script: endif
            • Else - Actions
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • (Max life of DamageEventTarget) Less than DmgEvLife
                • Then - Actions
                  • Unit - Add DamageBlockingAbility to DamageEventTarget
                  • Set VariableSet DmgEvStack[DmgEvN] = DamageEventTarget
                  • Set VariableSet DmgEvN = (DmgEvN + 1)
                  • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                    • If - Conditions
                      • DmgEvN Equal to 1
                    • Then - Actions
                      • Custom script: call TimerStart(udg_DmgEvTimer, 0, false, function DmgEvRemoveAbilities)
                    • Else - Actions
                • Else - Actions
              • Unit - Set life of DamageEventTarget to DmgEvLife
        • Else - Actions
      • Custom script: endfunction
      • Custom script:
      • Custom script: function FireRecursiveDmgEv takes nothing returns nothing
      • Custom script: local real d = udg_DamageEventAmount
      • Custom script: local unit s = udg_DamageEventSource
      • Custom script: local unit t = udg_DamageEventTarget
      • Custom script: local integer ptype = udg_DmgTypPrev
      • Custom script: local boolean explode = udg_DamageEventExplodesUnit
      • Custom script: local boolean override = udg_DamageEventOverride
      • Custom script: local real prev = udg_DamageEventPrevAmt
      • Custom script: call DmgEvSetVars()
      • Custom script: if udg_DamageEventTarget != t or udg_DamageEventSource != s or udg_DamageEventAmount != d or udg_DamageEventType != ptype then
      • Set VariableSet DamageEvent = 0.00
      • Set VariableSet DamageModifierEvent = 0.00
      • Custom script: call FireDmgEv()
      • -------- - --------
      • -------- Delete the next three lines to disable the in-game recursion crash warnings --------
      • -------- - --------
      • Custom script: else
      • Cinematic - Clear the screen of text messages for (All players).
      • Game - Display to (All players) for 999.00 seconds the text: WARNING: Recursion ...
      • -------- - --------
      • Custom script: endif
      • Custom script: set udg_DamageEventOverride = override
      • Custom script: set udg_DamageEventExplodesUnit = explode
      • Custom script: set udg_DamageEventPrevAmt = prev
      • Custom script: set udg_DmgTypPrev = ptype
      • Custom script: set udg_DamageEventAmount = d
      • Custom script: set udg_DamageEventSource = s
      • Custom script: set udg_DamageEventTarget = t
      • Custom script: set s = null
      • Custom script: set t = null
      • Custom script: endfunction
      • Custom script:
      • Custom script: function OnDmgEv takes nothing returns boolean
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • DamageEvent Equal to 0.00
        • Then - Actions
          • Set VariableSet DmgTypPrev = DamageEventType
          • Custom script: call DmgEvSetVars()
          • Custom script: call FireDmgEv()
          • Set VariableSet DamageModifierEvent = 0.00
          • Set VariableSet DamageEvent = 0.00
          • Set VariableSet DamageEventType = 0
        • Else - Actions
          • Custom script: call FireRecursiveDmgEv()
      • Custom script: return false
      • Custom script: endfunction
      • Custom script:
      • Custom script: function CreateDmgEv takes nothing returns nothing
      • Custom script: set udg_DamageEventTrigger = CreateTrigger()
      • Custom script: call TriggerAddCondition(udg_DamageEventTrigger, Filter(function OnDmgEv))
      • Custom script: endfunction
      • Custom script:
      • Custom script: function SetupDmgEv takes nothing returns boolean
      • Custom script: local integer pdex = udg_UDex
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • UnitIndexEvent Equal to 1.00
        • Then - Actions
          • Set VariableSet TempUnit = UDexUnits[UDex]
          • Custom script: if GetUnitAbilityLevel(udg_TempUnit, 'Aloc') == 0 and DmgEvFilter() then
          • Set VariableSet UnitDamageRegistered[UDex] = True
          • Trigger - Add to DamageEventTrigger the event (Unit - TempUnit Takes damage)
          • Custom script: endif
        • Else - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • UnitDamageRegistered[UDex] Equal to True
            • Then - Actions
              • Set VariableSet UnitDamageRegistered[UDex] = False
              • Set VariableSet DamageEventsWasted = (DamageEventsWasted + 1)
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • DamageEventsWasted Equal to 15
                • Then - Actions
                  • Set VariableSet DamageEventsWasted = 0
                  • Custom script: call DestroyTrigger(udg_DamageEventTrigger)
                  • Custom script: call CreateDmgEv()
                  • Set VariableSet UDex = UDexNext[0]
                  • Custom script: loop
                  • Custom script: exitwhen udg_UDex == 0
                  • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                    • If - Conditions
                      • UnitDamageRegistered[UDex] Equal to True
                    • Then - Actions
                      • Trigger - Add to DamageEventTrigger the event (Unit - UDexUnits[UDex] Takes damage)
                    • Else - Actions
                  • Set VariableSet UDex = UDexNext[UDex]
                  • Custom script: endloop
                  • Custom script: set udg_UDex = pdex
                • Else - Actions
            • Else - Actions
      • Custom script: return false
      • Custom script: endfunction
      • Custom script:
      • Custom script: function InitDamageEvent takes nothing returns nothing
      • Custom script: call CreateDmgEv()
      • Custom script: call TriggerAddCondition(GetTriggeringTrigger(), Filter(function SetupDmgEv))
      • Set VariableSet UnitIndexerEnabled = False
      • Custom script: set udg_TempUnit = CreateUnit(Player(15), 'uloc', 0, 0, 0)
      • Set VariableSet UnitIndexerEnabled = True
      • Unit - Add DamageBlockingAbility to TempUnit
      • Unit - Remove TempUnit from the game
      • Countdown Timer - Start DmgEvTimer as a One-shot timer that will expire in 0.00 seconds
      • Trigger - Run (This trigger) (checking conditions)
 
Level 24
Joined
Feb 9, 2009
Messages
1,787
Lol, Looks like an old version, also you need to find the Cheat death ability and set it to the variable at the top here:
upload_2020-8-21_13-31-34.png


So make a roar ability, strip it of all it's stats (I.e. damage boost.) and make it last however long you want the effect to last.
Start with the event:
upload_2020-8-21_13-33-42.png


Then condition, set the buff to whatever the roar is using:
upload_2020-8-21_13-34-44.png


And finally set a variable that modifies the damage:
upload_2020-8-21_13-37-31.png


I'd still recommend playing with the current damage engine test map, you can learn quite a bit from seeing how each effect and modification works.
Lastly I'd also suggest reading through the documentation Bribe has painstakingly put on the damage engine page to see about updating, I believe you can just swap it out, but I'd make a back up first.

Oh, and to include "levels" just create four different buffs for each level and adjust accordingly.
  • Untitled Trigger 002
    • Events
      • Game - DamageModifierEvent becomes Equal to 3.00
    • Conditions
      • Or - Any (Conditions) are true
        • Conditions
          • (DamageEventTarget has buff Roar) Equal to True
          • (DamageEventTarget has buff 2 ) Equal to True
          • (DamageEventTarget has buff 3 ) Equal to True
          • (DamageEventTarget has buff 4 ) Equal to True
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (DamageEventTarget has buff 4 ) Equal to True
        • Then - Actions
          • Set DamageEventAmount = (DamageEventAmount x 0.45)
        • Else - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • (DamageEventTarget has buff 3 ) Equal to True
            • Then - Actions
              • Set DamageEventAmount = (DamageEventAmount x 0.55)
            • Else - Actions
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • (DamageEventTarget has buff 2 ) Equal to True
                • Then - Actions
                  • Set DamageEventAmount = (DamageEventAmount x 0.65)
                • Else - Actions
                  • Set DamageEventAmount = (DamageEventAmount x 0.75)
 
Last edited:
Level 14
Joined
Jul 19, 2007
Messages
772
Lol, Looks like an old version, also you need to find the Cheat death ability and set it to the variable at the top here:
View attachment 362457

So make a roar ability, strip it of all it's stats (I.e. damage boost.) and make it last however long you want the effect to last.
Start with the event:
View attachment 362458

Then condition, set the buff to whatever the roar is using:
View attachment 362459

And finally set a variable that modifies the damage:
View attachment 362460

I'd still recommend playing with the current damage engine test map, you can learn quite a bit from seeing how each effect and modification works.
Lastly I'd also suggest reading through the documentation Bribe has painstakingly put on the damage engine page to see about updating, I believe you can just swap it out, but I'd make a back up first.

Oh, and to include "levels" just create four different buffs for each level and adjust accordingly.
  • Untitled Trigger 002
    • Events
      • Game - DamageModifierEvent becomes Equal to 3.00
    • Conditions
      • Or - Any (Conditions) are true
        • Conditions
          • (DamageEventTarget has buff Roar) Equal to True
          • (DamageEventTarget has buff 2 ) Equal to True
          • (DamageEventTarget has buff 3 ) Equal to True
          • (DamageEventTarget has buff 4 ) Equal to True
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (DamageEventTarget has buff 4 ) Equal to True
        • Then - Actions
          • Set DamageEventAmount = (DamageEventAmount x 0.45)
        • Else - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • (DamageEventTarget has buff 3 ) Equal to True
            • Then - Actions
              • Set DamageEventAmount = (DamageEventAmount x 0.55)
            • Else - Actions
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • (DamageEventTarget has buff 2 ) Equal to True
                • Then - Actions
                  • Set DamageEventAmount = (DamageEventAmount x 0.65)
                • Else - Actions
                  • Set DamageEventAmount = (DamageEventAmount x 0.75)
Looks kinda complicated and hard for me to do and reading is not my strongest side... I can't see how this will reduced RANGED damage taken :-/
 
Level 14
Joined
Jul 19, 2007
Messages
772
Still got no help to make this ability :( Please make a spellpack for me with the ability I can't figure out how to do this ability myself. You said this ability could easily be done with DDS but I know nothing about it and I seems to be unable to learn about it too :( Not even my friend can help me do this ability so please try to make it for me!
 
Level 20
Joined
Feb 23, 2014
Messages
1,264
Please help me create this ability because I can't understand how the "damage engine" works like. It's just a jungle of triggers for me and I understand nothing
You don't need to understand how the damage detection system works. You don't even need to look at the triggers. All you need to do is download the map from the system's page (linked above), open it in the World Editor and copy the damage engine folder to your map. Once you do that, the system is ready to be used.

I don't really see what's causing you problems, but if it's difficult for you to copy DDS triggers from the system's map to your own then having someone make the ability for you won't help, because using that will also require copying the exact same DDS triggers to your map, so it's not going to get any easier.

As for the ability itself, @Devalut explained step by step how to make it. Just try to follow that and if you run into any problems, explain where you got stuck.
 
Last edited:

Uncle

Warcraft Moderator
Level 64
Joined
Aug 10, 2018
Messages
6,540
With the latest version of Damage Engine you don't need to do ANYTHING besides copy and paste the Folder called "Damage Engine" into your Trigger Editor. @Devalut That cheat death ability is no longer used.

Make sure you delete your old Damage Engine and every variable that came with it before pasting the new one into your map.

I also think you need to have "Automatically create unknown variables when pasting trigger data" enabled in the World Editor's File/Preferences/General.

My trigger is basically the same as Devaluts (I changed the Event):
  • Reduce Ranged Damage
    • Events
      • Game - DamageEvent becomes Equal to 1.00
    • Conditions
      • IsDamageRanged Equal to True
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (DamageEventTarget has buff Damage Reduction (Level - 1)) Equal to True
        • Then - Actions
          • Set VariableSet DamageEventAmount = (DamageEventAmount x 0.75)
        • Else - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • (DamageEventTarget has buff Damage Reduction (Level - 2)) Equal to True
            • Then - Actions
              • Set VariableSet DamageEventAmount = (DamageEventAmount x 0.65)
            • Else - Actions
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • (DamageEventTarget has buff Damage Reduction (Level - 3)) Equal to True
                • Then - Actions
                  • Set VariableSet DamageEventAmount = (DamageEventAmount x 0.55)
                • Else - Actions
                  • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                    • If - Conditions
                      • (DamageEventTarget has buff Damage Reduction (Level - 4)) Equal to True
                    • Then - Actions
                      • Set VariableSet DamageEventAmount = (DamageEventAmount x 0.45)
                    • Else - Actions
You can use DamageEvent becomes Equal to 1.00 in the latest version to modify damage before it's dealt.

@Dinodin
Understand that a Damage Engine is simply a set of triggers that someone created, no different than the triggers that you've created yourself. These "systems" come with Variables and instructions on how to use them.

So why do we need a special system?

The Damage Engine is needed because Blizzard originally didn't have a GUI-friendly way for detecting when a unit takes damage. The recent patches have given us more control over this but that doesn't mean the Damage Engine is no longer needed, it still does all of the work for you and Bribe's system is very solid and up to date.

So after you copy the system over to your map, how do you use it?

So in this case you need to create a new trigger that will handle the "Damage Event". This new trigger uses a "custom" Event, which is basically Blizzard's way of allowing us to create our own Events.

Here's the Event (it's one of many that come with the System but it's the main one):
  • Game - DamageEvent becomes Equal to 1.00
After you have a trigger with that Event you're free to do whatever you'd normally do in a standard trigger, but this time instead of using Event Responses like "Triggering Unit", you need to reference the Variables that come with the Damage Engine system.

The main Variables are:

IsDamageMelee = If TRUE then the damage was from a melee attack
IsDamageRanged = If TRUE then the damage was from a ranged attack
IsDamageSpell = If TRUE then the damage was from a spell like Shockwave
IsDamageCode = If TRUE then the damage was from a trigger like "cause unit to deal X damage"
DamageEventSource = The unit that dealt the damage
DamageEventTarget = The unit that got damaged
DamageEventAmount = The amount of damage being dealt (you can modify this variable to change the damage dealt!)

So looking back at my trigger above:
-The Event goes off whenever a unit takes damage.
-We check if the Damage is coming from a Ranged attack (IsDamageRanged = True).
-After confirming that it's Ranged damage, we check to see if the Damaged unit (DamageEventTarget) has one of the buffs associated with our Roar ability. If it does, we reduce the damage dealt (DamageEventAmount) by the correct amount.

Example: DamageEventAmount*0.75 will reduce the damage dealt by 25%.
 

Attachments

  • Reduce Ranged Damage.w3m
    55.9 KB · Views: 12
Last edited:
Level 14
Joined
Jul 19, 2007
Messages
772
With the latest version of Damage Engine you don't need to do ANYTHING besides copy and paste the Folder called "Damage Engine" into your Trigger Editor. @Devalut That cheat death ability is no longer used.

Make sure you delete your old Damage Engine and every variable that came with it before pasting the new one into your map.

I also think you need to have "Automatically create unknown variables when pasting trigger data" enabled in the World Editor's File/Preferences/General.

My trigger is basically the same as Devaluts (I changed the Event):
  • Reduce Ranged Damage
    • Events
      • Game - DamageEvent becomes Equal to 1.00
    • Conditions
      • IsDamageRanged Equal to True
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (DamageEventTarget has buff Damage Reduction (Level - 1)) Equal to True
        • Then - Actions
          • Set VariableSet DamageEventAmount = (DamageEventAmount x 0.75)
        • Else - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • (DamageEventTarget has buff Damage Reduction (Level - 2)) Equal to True
            • Then - Actions
              • Set VariableSet DamageEventAmount = (DamageEventAmount x 0.65)
            • Else - Actions
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • (DamageEventTarget has buff Damage Reduction (Level - 3)) Equal to True
                • Then - Actions
                  • Set VariableSet DamageEventAmount = (DamageEventAmount x 0.55)
                • Else - Actions
                  • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                    • If - Conditions
                      • (DamageEventTarget has buff Damage Reduction (Level - 4)) Equal to True
                    • Then - Actions
                      • Set VariableSet DamageEventAmount = (DamageEventAmount x 0.45)
                    • Else - Actions
You can use DamageEvent becomes Equal to 1.00 in the latest version to modify damage before it's dealt.

@Dinodin
Understand that a Damage Engine is simply a set of triggers that someone created that come with Variables and some instructions on how to use them.

The Damage Engine is needed because Blizzard didn't create GUI-friendly Damage events/conditions/actions for us to use. That's why we had to create a system ourselves using Variables to represent the "custom" Events and Event Responses. That's all the Damage Engine is, a system that makes handling Damage easy to do.

So after you copy the system over to your map, how do you use it?

So in this case you need to create a new trigger that will handle the "Damage Event". This new trigger uses a "custom" Event, which is basically Blizzard's way of allowing us to create our own Events.

Here's the Event (it's one of many that come with the System but it's the main one):
  • Game - DamageEvent becomes Equal to 1.00
After you have a trigger with that Event you need to add your Conditions/Actions to it. This is done by referencing the Variables that came with the Damage Engine system.

The main Variables are:

IsDamageMelee = If TRUE then the damage was from a melee attack
IsDamageRanged = If TRUE then the damage was from a ranged attack
IsDamageSpell = If TRUE then the damage was from a spell like Shockwave
IsDamageCode = If TRUE then the damage was from a trigger like "cause unit to deal X damage"
DamageEventSource = The unit that dealt the damage
DamageEventTarget = The unit that got damaged
DamageEventAmount = The amount of damage being dealt (you can modify this variable to change the damage dealt!)

So looking at my trigger above:
The Event goes off whenever a unit takes damage.
From there the Conditions and Actions can be used like you would in ANY other trigger.
You just need to reference the Variables I posted above instead of something like "Triggering Unit".
Oh thank you so much! But why is some triggerings in the DDS unabled? Do I have to set them on?
 

Attachments

  • dds.png
    dds.png
    12.6 KB · Views: 27
Status
Not open for further replies.
Top