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

[Mapping] How to make a maze + tips

Do you like this?


  • Total voters
    2
Level 6
Joined
Jan 26, 2009
Messages
98

How to make a maze + tips.


I've noticed there are no tutorials that tell you how to make a maze efficiently enough for its method to be used in escape builder maps.


-What is a maze? A maze is barely passable collection of paths which if you don' follow them you die, with patrolling monsters that touch you to kill and mortar teams firing at a periodic time and so on, you get the idea.

-How do I make one? There are loads of ways to make a maze but all mazes have one thing. One type of path that kills and one that you can walk on. The following trigger will tell you what a really basic maze have and how to make them.


  • killing path trigger
  • Walk off path
    • Events
      • Time - Every 0.05 seconds of game time
    • Conditions
    • Actions
      • Set -YourUnitGroup- = (Units of type -your escaper here-) and do (Actions)
      • Unit Group - Pick every unit in -YourUnitGroup- (Actions)
        • Loop - Actions
          • Set -YourLocation- = (Position of (Picked unit)))
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • Or - Conditions
                • (Terrain type at -YourLocation- here-) Equal to (-your killer ground here-)
            • Then - Actions
              • Unit - Kill (Picked Unit)
            • Else - Actions
      • Custom script: call DestroyGroup(udg_-YourUnitGroup-)
      • Custom script: call RemoveLocation(udg_-YourLocation-)

  • -a basic lives trigger. See the following.

Step 1: Make an array called PlayerLB and another array called Lives, both with 12 indexes.

Step 2:Now lets setup a leaderboard containing the value of RedLives.
  • Lives Leaderboard
    • Events:
      • Time - Elapsed game time is 0.30 seconds
    • Conditions:
    • Actions:
      • Leaderboard - Create a leaderboard for (All players) titled Player Lives
      • For each (Integer A) from 1 to 12, do (Actions)
        • Loop - Actions
          • Set PlayerLB(Integer A) = Player(Integer A)
          • Leaderboard - Add Player(Integer A) to (Last created leaderboard) with label Lives and value Lives(Integer A)
      • Leaderboard - Show (Last created leaderboard)
Step 3: Now that you have created a leaderboard you probably want to see the lives value change. Well then make this trigger!
  • Trigger4:Lives Lost Red
    • Events:
      • Unit - A unit dies
    • Conditions:
      • (Owner of (Dying unit)) Not equal to Player 12 (Brown)
    • Actions:
    • For each (Integer A) from 1 to 12, do (Actions)
      • Loop - Actions
        • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
          • If - Conditions
            • (Owner of (Dying unit)) Equal to Player(Integer A)
          • Then - Actions
            • Set Lives[(Integer A)] = (Lives[(Integer A)] - 1)
          • Else - Actions
      • Unit - Remove (Dying unit) from the game
      • Leaderboard - Change the value for Player 1 (Red) in (Last created leaderboard) to RedLives
      • Trigger - Run Defeat (checking conditions)
The Defeat Trigger....
  • Defeat
    • Events:
    • Conditions:
    • Actions:
      • For each (Integer A) from 1 to 12, do (Actions)
        • Loop - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • Lives[1] less than or equal to 0
            • Then - Actions
              • Game - Defeat Player (Integer A) with the message: -Any message here-
            • Else - Actions
-Respawn

  • Rez
    • Events
      • Unit - A unit comes within 256.00 of -escaper-
    • Conditions
      • (Unit-type of (Triggering unit)) Equal to Respawnpoint
    • Actions
      • Set Respawnplace = (Position of (Triggering unit))
and
  • Rez2
    • Events
      • Unit - A unit Dies
    • Conditions
      • (Owner of (Dying unit)) Not equal to Player 12 (Brown)
    • Actions
      • Hero - Instantly revive (Dying unit) at Respawnplace, Show revival graphics
Well, that's a basic maze. The very basic, but you cannot find mazes like that.

-------------------------------------------------------------------------

You can add the following (also basic) components...

-The example trigger. It is the very backbone of the map, you can keep adding to it.

  • Example trigger
    • Events
      • Unit - A unit comes within (45) of (-escaper-)
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Unit-type of (Triggering unit)) equal to (-whatever unit or building-)
        • Then - Actions
          • Set MyUnitGroup = (Units within 45.00 of (Position of (Triggering unit)))
          • Unit Group - Pick every unit in MyUnitGroup and do (Actions)
            • Loop - Actions
              • Set Unitgroup1 = (Last created unit group)
              • Unit Group - Remove (Triggering unit) from (Last created unit group)
              • Fill in what you want it to do. Teleport, kill or become a rez place?
        • Else - Actions
          • The if conditions thing again if you need more.
      • Custom script: call DestroyGroup(udg_MyUnitGroup)
-Killer monsters. Use the following...
  • Patrol1
    • Events
      • Unit - A unit enters (-your region-)
    • Conditions
      • ((UNIT-TYPE) of (TRIGGERING UNIT)) equal to (-CREEP UNIT-)
    • Actions
      • Unit - Order (TRIGGERING UNIT) to MOVE TO (CENTER OF (-your region2-))
and
  • Patrol2
    • Events
    • Unit - A unit enters (-your region2-)
    • Conditions
      • ((UNIT-TYPE) of (TRIGGERING UNIT)) equal to (-CREEP UNIT-)
    • Actions
      • Unit - Order (TRIGGERING UNIT) to MOVE TO (CENTER OF (-your region-))
add the following to the example trigger
  • Killer
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • Unit type of (Triggering unit) equal (-CREEP UNIT-)
        • Then - Actions
          • Set MyUnitGroup = (Units within 45.00 of (Position of (Triggering unit)))
          • Unit Group - Pick every unit in MyUnitGroup (Actions)
            • Loop - Actions
              • Set Unitgroup1 = (Last created unit group)
              • Unit Group - Remove (Triggering unit) from (Last created unit group)
              • Unit - Kill (-escaper-)
        • Else - Actions
          • The if conditions thing again if you need more.
-shooters. Use the following...
  • Patrol1
    • Events
      • Unit - A unit enters (-your region3-)
    • Conditions
      • ((UNIT-TYPE) of (TRIGGERING UNIT)) equal to (-bomb target-)
    • Actions
      • Unit - Order (TRIGGERING UNIT) to MOVE TO (CENTER OF (-your region4-))
and
  • Patrol2
    • Events
      • Unit - A unit enters (-your region4-)
    • Conditions
      • ((UNIT-TYPE) of (TRIGGERING UNIT)) equal to (-bomb target-)
    • Actions
      • Unit - Order (TRIGGERING UNIT) to MOVE TO (CENTER OF (-your region3-))
and
  • Bomb
    • Events
      • Every 3.00 seconds of game time.
    • Conditions
    • Actions
      • Unit - Order (-CATAPULT CREEP-) to ATTACK (-bomb target-)
P.S. Make the catapult creep deal 999999999 damage to all armor except bomb target's armor.

-More Ideas:

Terrain Change:

Use a terrain changer that changes the tile next to it horizontally and changes the tile next next to it horizontally walkable tile and unwalkable tile respectively. Add these to the example trigger...
  • More stuff to add
    • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
      • If - Conditions
        • (Unit-type of (Triggering unit)) equal to (-terrain changer-)
      • Then - Actions
        • Set MyUnitGroup = (Units within 45.00 of (Position of (Triggering unit))) and do (Actions)
        • Unit Group - Pick every unit in MyUnitGroup (Actions)
          • Loop - Actions
            • Unit Group - Remove (Triggering unit) from (Last created unit group)
              • Set MyLocation = offset by (any, any)) to -your killer ground here- using variation -1 in an area of size 1 and shape Circle
              • Set MyLocation1=((Position(Triggeringunit))MyLocation
              • Environment - Change terraintype at MyLocation1 Circle offset by (any, any)) to -your killer ground here- using variation -1 in an area of size 1 and shape Circle
              • Custom script: call RemoveLocation(udg_MyLocation1)
      • Else - Actions
        • The if conditions thing again if you need more.
Using Fade Filters for Confusion

You can make a fade filter with a transparent gap to see the player and make a trigger to fix the camera to the player to make it look like a DARK cave and harder to see, or you could grant no invisibility and instead give the heroes lesser radius so that they see less.

Moving Mazes

The walls are units and they patrol and you must still keep to the path without touching the units, it is useful for traps and such. Use the killer trigger for the units to kill.

Traps

Things like units come from no where and trap you, an item gets stuck, you must hit switches to get past stuff etc. it is very useful to make your maze more fun! Add the following to the example.

  • More stuff to add 2
    • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
      • If - Conditions
        • (Unit-type of (Triggering unit)) equal to (-your trap-)
      • Then - Actions
        • Set MyLocation = (Position of (Triggering unit))) and do (Actions)
        • Set YourUnitGroup = (Units within 45.00 of (MyLocation))
    • Unit Group - Pick every unit in (YourUnitGroup) and do (Actions)
      • Loop - Actions
        • Unit Group - Remove (Triggering unit) from (YourUnitGroup)
        • The trap's function here
      • Else - Actions
        • The if conditions thing again if you need more.
    • Custom script: call RemoveLocation(udg_MyLocation)
    • Custom script: call DestroyGroup(udg_YourUnitGroup)
Boss Levels

if you have levels in your maze then this idea is a good choice, have a boss which moves about and you have to do something in the level which makes it lose health, when it dies a gate opens so that you can escape to the next part of the maze. Your imagination, your trigger.

Choose an escaper

  • Type-select a escaper
    • Events
      • Player - Player 1 (Red) types a chat message containing -Fast escaper as An exact match
      • Player - Player 2 (Blue) types a chat message containing -Fast escaper as An exact match
      • Player - Player 3 (Teal) types a chat message containing -Fast escaper as An exact match
      • Player - Player 4 (Purple) types a chat message containing -Fast escaper as An exact match
      • Player - Player 5 (Yellow) types a chat message containing -Fast escaper as An exact match
      • Player - Player 6 (Orange) types a chat message containing -Fast escaper as An exact match
      • Player - Player 7 (Green) types a chat message containing -Fast escaper as An exact match
      • Player - Player 8 (Pink) types a chat message containing -Fast escaper as An exact match
      • Player - Player 9 (Gray) types a chat message containing -Fast escaper as An exact match
      • Player - Player 10 (Light Blue) types a chat message containing -Fast escaper as An exact match
    • Conditions
    • Actions
      • Set YourLocation = (Center of Startpoint <gen>)
      • Unit - Create 1 Fast escaper for (Triggering player) at (YourLocation <gen>) facing 90.00 degrees
      • Set Escaper[Player number of (Triggering player] = (Last created unit)
      • Custom script: call RemoveLocation(udg_YourLocation)
      • Custom script: call DestroyTrigger(GetTriggeringTrigger())
(I'll add a test map the moment I'm not grounded from playing wc3... at the meantime, take escape builder as an example or the moment my mum goes to the gym...)

P.S. You have to use variables in some triggers.
P.P.S. I know there is another maze maker tutorial, but this is more for an escape builder type of map.
P.P.P.S. You need to make all non-escaper units invulnerable or unable to take damage, but hittable.
P.P.P.P.S. I used Leak Check V3 to check for leaks. May be inaccurate.
 
Last edited:
You should explain a bit more what are the key components of a maze. For example, instead of showing the triggers immediately, make sure you have a brief introduction to each one showing what you are trying to do. For the later part of the tutorial, you should include examples, especially of things like traps, as that is what people concern heavily on for mazes.

For this type of tutorial, you may want to include a test map as well, as that will let people see the triggers in action and be able to model their mazes after it.
 
Level 9
Joined
Feb 3, 2010
Messages
660
You should explain a bit more what are the key components of a maze. For example, instead of showing the triggers immediately, make sure you have a brief introduction to each one showing what you are trying to do. For the later part of the tutorial, you should include examples, especially of things like traps, as that is what people concern heavily on for mazes.

For this type of tutorial, you may want to include a test map as well, as that will let people see the triggers in action and be able to model their mazes after it.

You are right, there needs a test map.

This looks like as a list of triggers should be triggered on maze maps... =/ So explain more of these triggers as like "Why I must have it?","Is it good to use?" and "Things to think at!" . Don't forgot that to explain these tips triggers what they will work.
 
Level 6
Joined
Jan 26, 2009
Messages
98
You are right, there needs a test map.

This looks like as a list of triggers should be triggered on maze maps... =/ So explain more of these triggers as like "Why I must have it?","Is it good to use?" and "Things to think at!" . Don't forgot that to explain these tips triggers what they will work.

This is not nursery, an experienced coder knows how to understand triggers. Also, I'm waiting to sneak in a test map the moment mum goes gym.

P.S. This tutorial is not a reference to GUI.
 
Last edited:
Top