• 🏆 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!
  • 🏆 Hive's 6th HD Modeling Contest: Mechanical is now open! Design and model a mechanical creature, mechanized animal, a futuristic robotic being, or anything else your imagination can tinker with! 📅 Submissions close on June 30, 2024. Don't miss this opportunity to let your creativity shine! Enter now and show us your mechanical masterpiece! 🔗 Click here to enter!

[Solved] Need Helpt to fix damage trigger formula

Status
Not open for further replies.
Level 6
Joined
Jan 2, 2015
Messages
171
  • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
    • If - Conditions
      • DamageEventType Equal to 0
      • DMGS_Ability Equal to Compound Shot
    • Then - Actions
      • Unit Group - Pick every unit in (Units within 300.00 of (Position of DamageEventTarget) matching ((((Matching unit) is alive) Equal to True) and ((((Matching unit) belongs to an enemy of (Owner of DamageEventSource)) Equal to True) and ((Level of Invulnerable (Neutral) for (Matching unit)) and do (Actions)
        • Loop - Actions
          • Unit - Cause DamageEventSource to damage (Picked unit), dealing ((Real((Level of Compound Shot for DamageEventSource))) x ((Real((Intelligence of DamageEventSource (Include bonuses)))) + 200.00)) damage of attack type Spells and damage type Universal
i based my spell with storm bolt and set the spell damage to 0.01 so system can still detect damage from it. The problem is whenever i cast that spell..for example, there is 2 units near each other and i target one of them. the damage suddenly x2. That means when the damage is actually 300 for 1 target. it will multiply by 2 if it hits 2 unit at the same time. how do i fix it so enemy around it got same damage instead of multiplied one?
 
You use an Damage detection System, dont you.
If you damage inside the damage handling Trigger it wil retrigger it again -> 2x or more dmg.

to fix that either disable the system for the damage dealing or manipulate the Damageamount with an set variable action.
There should be some kind of variable with the Name "DamageEventAmount".
 
Level 6
Joined
Jan 2, 2015
Messages
171
You use an Damage detection System, dont you.
If you damage inside the damage handling Trigger it wil retrigger it again -> 2x or more dmg.

to fix that either disable the system for the damage dealing or manipulate the Damageamount with an set variable action.
There should be some kind of variable with the Name "DamageEventAmount".

still not working. loop still making system spamming damage on unit
 
Level 6
Joined
Jan 2, 2015
Messages
171
  • CompoundShotDamage
    • Events
      • Game - DamageModifierEvent becomes Equal to 1.00
    • Conditions
      • DamageEventType Equal to 0
      • DMGS_Ability Equal to Compound Shot
    • Actions
      • Set DamageEventAmount = ((Real((Level of Compound Shot for DamageEventSource))) x ((Real((Intelligence of DamageEventSource (Include bonuses)))) + 200.00))
      • Unit Group - Pick every unit in (Units within 300.00 of (Position of DamageEventTarget) matching ((((Matching unit) is alive) Equal to True) and ((((Matching unit) belongs to an enemy of (Owner of DamageEventSource)) Equal to True) and ((Level of Invulnerable (Neutral) for (Matching unit)) and do (Actions)
        • Loop - Actions
          • Unit - Cause DamageEventSource to damage (Picked unit), dealing DamageEventAmount damage of attack type Spells and damage type Normal
it still spam damage on unit. btw i use bribe damage engine.
 
Surround the Group loop with an enable disable Trigger block this will block multiple trigger runs in one execution.
But if you change damage EventAmount the main unit will take that amount of damage by the dmg engine so you should exclude it from the group else it will take the dmg twice.
  • Actions -
    • Trigger - Turn off (This trigger)
    • Unit Group - Pick every unit in (Units within 300.00 of (Position of DamageEventTarget) matching ((((Matching unit) is alive) Equal to True) and ((((Matching unit) belongs to an enemy of (Owner of DamageEventSource)) Equal to True) and ((Level of Invulnerable (Neutral) for (Matching unit)) and do (Actions)
      • Loop - Actions
        • Unit - Cause DamageEventSource to damage (Picked unit), dealing DamageEventAmount damage of attack type Spells and damage type Normal
    • Trigger - Turn on (This trigger)
 
Last edited:
Level 24
Joined
Aug 1, 2013
Messages
4,657
I assumed you had an AoE on the spell.
But afaik, Storm Bolt doesnt make use of the AoE field.
(Still worth to check if it indeed doesnt damage both targets without the trigger.)

Is the damage multiplied by 3 if there are 3 units and 4 if there are 4 units, etc?
 
Level 6
Joined
Jan 2, 2015
Messages
171
well might dumb solution for temporary fix until i can make this damage by trigger without hurting my caster. So i made trigger that whenever i cast my custom spell (based on storm bolt with custom missle and 3000 missile speed without damage), trigger will create dummy on position of target being cast then will use frost nova and i also change frost nova model to custom explosion model then my own caster. so basicly, my spell damage is fixed spell and if i can get other suggestion about making it working by trigger. i will be more happy about it since Wietlol solution does not work..it cause my caster also got damage whenever he is near target of ability being cast.
 
Status
Not open for further replies.
Top