• 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] or [JASS] - Maze System without Death Regions

Status
Not open for further replies.
Level 3
Joined
Oct 24, 2008
Messages
24
Well while building a Maze map... I've been thinking if its possible to instead of creating death regions/out path regions make a function which says when a unit owned by a player enters in a place where tileset type is Dust or Grass, or whatever the death tileset would be, the unit dies. Is it possible? That would be great, so I could just design the terrain instead of making death regions for all Maze maps I do.

Hope you understood,
Silk
 
Level 5
Joined
Feb 21, 2009
Messages
136
Just add the your units to the ''Mazers'' unit group
  • Check
    • Events
      • Time - Every 0.03 seconds of game time
    • Conditions
    • Actions
      • Unit Group - Pick every unit in Mazers and do (Actions)
        • Loop - Actions
          • Set Point = (Position of (Picked unit))
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • ((Picked unit) is alive) Equal to True
              • (Terrain type at Point) Equal to Lordaeron Summer - Dirt
            • Then - Actions
              • Unit - Kill (Picked unit)
            • Else - Actions
          • Custom script: call RemoveLocation(udg_Point)
Mazers = unit group
Point = point
 
Status
Not open for further replies.
Top