• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

[Trigger] Kill units within range of spell

Status
Not open for further replies.
Level 5
Joined
Mar 27, 2008
Messages
107
  • Massive Ent Roots
    • Events
      • Unit - A unit Begins casting an ability
    • Conditions
      • (Ability being cast) Equal to Blizzard
    • Actions
      • Unit Group - Pick every unit in (Units within 512.00 of (Target point of ability being cast) matching ((Owner of (Picked unit)) Equal to Player 5 (Yellow))) and do (Actions)
        • Loop - Actions
          • Unit - Kill (Picked unit)
Im getting really surprised this isnt working ;o such a simple trigger and ive looked it over and cant really find the problem ;o anyway any1 know whats wrong with it? :p
+rep for help
 
Level 18
Joined
Oct 18, 2007
Messages
930
  • Massive Ent Roots
    • Events
      • Unit - A unit Begins casting an ability
    • Conditions
      • (Ability being cast) Equal to Blizzard
    • Actions
      • Unit Group - Pick every unit in (Units within 512.00 of (Target point of ability being cast) matching ((Owner of (Picked unit)) Equal to Player 5 (Yellow))) and do (Actions)
        • Loop - Actions
          • Unit - Kill (Picked unit)
Im getting really surprised this isnt working ;o such a simple trigger and ive looked it over and cant really find the problem ;o anyway any1 know whats wrong with it? :p
+rep for help

Replace "matching ((Owner of (Picked unit))" with "mathing ((Owner of (Mathcing unit))".

And btw you leak a point and a group
 
Level 5
Joined
Mar 27, 2008
Messages
107
Ah lol thats embarressing <.< thx :)

Yeah I know, this was just a trigger I made fast as an example, Ill fix leaks in my final trigger :)

+rep
 
Level 7
Joined
Oct 14, 2008
Messages
340
Oh also, using Unit - Kill (Picked unit) Will kill the unit, but it won't register as being killed by the hero who casted the ability, i recommend triggering 99999 damage to the picked unit from the caster. Unless there's no bounty/kill count etc. in your map.
 
Status
Not open for further replies.
Top