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

area of effect damaging trigger?

Status
Not open for further replies.
Level 4
Joined
Oct 18, 2010
Messages
55
Hello all. Im a beginner mapper. Just want to ask simple question:

I was creating blizzard spell-like trigger which was dealing lets say 4x INT. But when i wanted it to damage AOE i used the "Unit - Damage Area" action. Problem is it was damaging friendly units too. Can someone please show me another way to make the same spell so it will damage only enemy units?

thanks :)
 
Level 37
Joined
Mar 6, 2006
Messages
9,240
  • Untitled Trigger 037
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to War Stomp
    • Actions
      • Set u1 = (Triggering unit)
      • Set p1 = (Position of u1)
      • Set Player = (Owner of u1)
      • Set r1 = (4.00 x (Real((Level of War Stomp for u1))))
      • Custom script: set bj_wantDestroyGroup = true
      • Unit Group - Pick every unit in (Units within 512.00 of p1 matching ((((Matching unit) is alive) Equal to True) and ((((Matching unit) belongs to an enemy of Player) Equal to True) and (((Matching unit) is A flying unit) Equal to False)))) and do (Actions)
        • Loop - Actions
          • Unit - Cause u1 to damage (Picked unit), dealing r1 damage of attack type Spells and damage type Normal
      • Custom script: call RemoveLocation(udg_p1)
It filters out dead, allied, neutral and flying units. Magic immune could be filtered also and other stuff you don't want to damage.
 
Status
Not open for further replies.
Top