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

[Solved] [Trigger Editor] Within Region

Status
Not open for further replies.
Level 4
Joined
Nov 17, 2015
Messages
91
Hey hive! I've been having a problem,
I'd like for when someone types -sell house, that all units inside region house, are killed. Can anyone help? Pictures are appreciated! :goblin_good_job:
 
Do you know anything about triggers?

It is difficult to answer people's question if you can't tell where their skill level is currently.

  • Events -
    • Player - Player 1 (Red) types a chat message containing -Sell House as An exact match
  • Conditions
  • Actions -
    • Unit Group - Pick all units within region X and do -
      • Actions - Loop
        • Unit - kill (picked unit)
This leaks though. Please read - Things that Leak
 
Level 4
Joined
Nov 17, 2015
Messages
91
Well this isn't exactly coding. This is more of, does warcraft 3's trigger editor have the option. Thanks for the help! :goblin_good_job:
Question though, is there a way to do so without it leaking?

EDIT: Oops never-mind, the article you linked me to explains that I think. Thanks friend!
 
Level 4
Joined
Nov 17, 2015
Messages
91
Hey, I encountered a problem. I can't figure out the loop option.
Here is what I have:
  • Unit Group - Pick every unit in (Units in Evict <gen>) and do (For each (Integer A) from (Integer A) to (Integer B), do (Unit - Kill (Picked unit)))
How do I make it loop?
 
Level 37
Joined
Jul 22, 2015
Messages
3,485
Hey, I encountered a problem. I can't figure out the loop option.
Here is what I have:
  • Unit Group - Pick every unit in (Units in Evict <gen>) and do (For each (Integer A) from (Integer A) to (Integer B), do (Unit - Kill (Picked unit)))
How do I make it loop?

When you go down to the Unit Group actions list, you will see two options:
  • Unit Group - Pick Every Unit in Unit Group And Do Multiple Actions
  • Unit Group - Pick Every Unit in Unit Group and Do Action

Select the option that says multiple actions.
 
Status
Not open for further replies.
Top