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

unit dies w/ a buff... help!

Status
Not open for further replies.
Level 4
Joined
Feb 25, 2008
Messages
58
I want one of my spells to make it so that when a unit dies, if it has a certain buff, it damages nearby units. Here's the trigger I made.. can anyone find a problem with it?
  • Taint
    • Events
      • Unit - A unit Dies
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • ((Triggering unit) has buff Taint (Level 1)) Equal to True
        • Then - Actions
          • Unit Group - Pick every unit in (Units within 100.00 of (Position of (Triggering unit)) matching (((Matching unit) belongs to an ally of (Owner of (Triggering unit))) Equal to True)) and do (Unit - Cause (Killing unit) to damage (Picked unit), dealing 45.00 damage of attack type Chaos and damage type Normal)
        • Else - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • ((Triggering unit) has buff Taint (Level 2)) Equal to True
            • Then - Actions
              • Unit Group - Pick every unit in (Units within 125.00 of (Position of (Triggering unit)) matching (((Matching unit) belongs to an ally of (Owner of (Triggering unit))) Equal to True)) and do (Unit - Cause (Killing unit) to damage (Picked unit), dealing 90.00 damage of attack type Chaos and damage type Normal)
            • Else - Actions
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • ((Triggering unit) has buff Taint (Level 3)) Equal to True
                • Then - Actions
                  • Unit Group - Pick every unit in (Units within 150.00 of (Position of (Triggering unit)) matching (((Matching unit) belongs to an ally of (Owner of (Triggering unit))) Equal to True)) and do (Unit - Cause (Killing unit) to damage (Picked unit), dealing 135.00 damage of attack type Chaos and damage type Normal)
                • Else - Actions
                  • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                    • If - Conditions
                      • ((Triggering unit) has buff Taint (Level 4)) Equal to True
                    • Then - Actions
                      • Unit Group - Pick every unit in (Units within 175.00 of (Position of (Triggering unit)) matching (((Matching unit) belongs to an ally of (Owner of (Triggering unit))) Equal to True)) and do (Unit - Cause (Killing unit) to damage (Picked unit), dealing 180.00 damage of attack type Chaos and damage type Normal)
                    • Else - Actions
                      • Do nothing
Thanks for your help/time.
-NS
 
Level 11
Joined
Dec 31, 2007
Messages
780
besides... if your unit dies with buff lvl 2 nothing will hapen because first you check for lvl 1... if it is lvl 2 it is not lvl 1 so it will never run

same for 3 and 4

if it works for skill lvl 1 it is what i say...

if not... then its because units dead has no buff
 
Last edited:
Level 11
Joined
Jun 21, 2007
Messages
505
Yes, use "AOE Damage on Death" ability, just hit ctrl+f when in Object Editor (to search) and type "AOE" there (AOE means Area OF Effect). Use trigger action "Set level of ability for unit".

And unit , I think, loses all his buffs on death. You can try "Unit - A unit is attacked" event and "Unit's life less than or equal to 20" condition "Unit - Explode" action and queue your trigger.
 
Status
Not open for further replies.
Top