DeadMeat's Tutorial Logo (by KruGer)
Quake - Lesson 8 - Stupid Monster Tricks


Note: if you've never used BSP before, I suggest that you review some of my General BSP tutorials to get a feel for using the editor. These tutorials for Quake-specific items will be geared to people who are already comfortable with BSP.

Just to prove that I listen to my loyal 'students', I'm posting this lesson. The idea for this lesson came from Jeremy Lennert. He wanted to know how to make a monster teleportation trap and how to trigger events to happen after monsters were killed. Well, I thought that sounded like a good subject for a tutorial lesson, so here it is...

In order to allow us to play around with monsters, I've created a map to use. You can download it here. Unzip this map and put it in your C:\QBSP directory. Load it into BSP and we're off. Remember, that if you're using a different texture wad than Quake101.wad, you'll need to edit the map file and possibly change some textures to make this work on your system.

Before we do anything constructive, let's compile the map and run it in Quake so we have a feel for what it looks like. Go ahead and run it. As you can see in the screenshot below, the player appears on a platform over a slime pit. There is a 'bridge' to another platform. If you fall in the slime, you can climb back up to the platform by running up the ramp I've provided. This is a good idea to have in any map where there is some hazard. Give your players a chance to get out if they fall (or jump) in.

Quake Screenshot


The plan is to make it so that as the player crosses the bridge, enforcers appear in front of and behind him/her, creating an ambush. Also, note that if you shoot the wall straight ahead of you, you'll find a secret door. This is the door we will open after the enforcers have been killed.

Okay, if you're done playing, let's get started. Load the map into BSP if it's not already there. Switch to the Top View and set your zoom to 50%. You'll notice that we have the main room where all the action takes place, as well as the secret room which will be revealed after the monsters are killed. But, there is also a large room on the right side of the screen that has no entities or lights in it and is not connected to the rest of the map in any way. This is where we will put our monsters while they await teleportation. This room can be anywhere, I just chose to put it here so it would be closeby.

The first thing we need to do is make our monsters. Make a 32x32 brush in the Top View somewhere in this empty room. I chose the Northeast corner, but it can be anywhere. Make this into a 'monster_enforcer' entity and in a side view make sure the monster is sitting against the floor. Now, copy this monster and put the other copy a little ways away from the first one. These are the monsters we will use to ambush the unsuspecting player.

The next thing we need to do is make a 48x48 brush around one of the monsters. Make this brush 80 units tall and again, make sure it is sitting against the floor. Now make this brush into a 'trigger_teleport' entity. Make sure that the monster entity is fully contained within this trigger. That way, when it activates, the monster will be teleported. When you have this one sized and shaped like you need, copy it and put the pasted copy around the other monster. Those are the triggers which will actually teleport the monsters.

In order to make the teleporting work properly, we need a landing spot for each monster. Go over to the main room and make a 16x16 brush centered on (-312, -32) in the top view. Make this into an 'info_teleport_destination' entity. Give it and angle setting of 0. Switch to a side view and make sure that the bottom edge of the brush is sitting at 192 on the Z axis. This makes the monster appear on the platform, right at the edge of the bridge. Now, copy this entity and move the pasted copy so that it is centered at (24, -32). Give this new entity an angle setting of 180. Now the two monsters will face the player (who is in the middle of the bridge at the time they appear) when they teleport into the room.

The next step is to link the teleport entities with their destination. Select one of the teleportation triggers (make sure the monster inside is not selected) and then CTRL-Left-Click on one of the teleport destination entities. It doesn't matter what one you use. When you've finished, select the other teleportation trigger and connect it to the other destination spot in the same manner.

Our monsters will teleport now, but we have to make a trigger to activate the trap. In the Top View, make a brush from (-192, 208) to (-184, -304). Switch to a side view and stretch this brush from the floor to the ceiling of the main room. That way it fills the entire room and the trigger cannot be avoided, even if the player is in the slime. Make this brush into a 'trigger_once' entity, then with that trigger still selected, CTRL-Left-Click on one of the teleportation triggers. Now, select the teleportation trigger you just connected to and switch to the Entity Window. Look for the trigger number BSP assigned to the 'targetname' key of this entity. On my map this is 't3'. Remember this value and then select the other teleport trigger. Add a key/value pair to this trigger of 'targetname' 't3' (or whatever value BSP used in your map). This will link the single 'trigger_once' entity to both teleport triggers. I haven't found a way to use BSP to make more than one connection from a single entity using CTRL-Left-Click, so we have to do the second one manually.

With all that done, your map should look something similar to this screenshot. If yours doesn't look exactly like that don't worry, just make sure the purple connecting lines on your map run like they do on mine.

Okay, run your map in Quake and see if everything is working all right. As you cross the bridge, the enforcers should appear in front of you and behind you. If everything works, great! If not, re-read the above steps and try again.

Once you get everything working properly, we're ready to make the monsters trigger the secret door when they die. If you just have one monster, you could simply select the monster and then CTRL-Left-Click on the door to attach them together. In our case we want both monsters to be dead before the door opens, so we need to use a 'trigger_counter' entity (remember we used these before).

To do this, make a brush somewhere in the main room, but somewhere out of the way. Size and shape don't matter because this brush won't be visible. Just be sure that the brush is within the confines of the level. If it's outside the map, remember that QBSP will generate a leak. Make this brush into a 'trigger_counter' entity, assign a key/value pair of 'count' '2' (since we have 2 monsters) and then CTRL-Left-Click on the secret door to attach the two together.

The only thing remaining to do now is to attach the monsters to the trigger_count entity. Now we have a slight problem. The monster entities are fully enclosed within the teleport triggers, so we need to separate them for a moment. Select each teleport trigger and move it away from the monster entity a little ways. Then select one monster, CTRL-Left-Click on the 'trigger_counter' entity. Now, select the 'trigger_counter' and see what trigger number BSP assigned (mine was 't5'). Select the other monster and assign a key/value of 'target' 't5' to attach it to the 'trigger_counter' also. When you are done, move the teleport entities back to their original places surrounding the monsters.

Okay, run your map now and try shooting the secret door. It won't open now. Cross the bridge and the two monsters appear. Kill one of them. Notice that Quake displays a message stating you have one more to go. Kill the other one and it says 'Sequence Completed'. Now the secret door should open. Cool, huh?

Well, that was fun wasn't it? Hope everything worked well for you and your map works. If not, here is a link to the one I made so you can look at it and try to figure out what went wrong.

Here's a little tidbit I'll throw out in case you ever use the trigger_counter in your own maps. If you've downloaded my Dead Simple map and played it, you probably noticed that I use the trigger_counter to control the walls and the exit door after you kill various sets of monsters. I ran into an interesting thing when making that level. In the different skill levels, I have a different number of monsters. In order to make this map work, I had to make a separate trigger_counter entity for each skill level, with its count value set to the number of monsters appearing in that skill level. This trigger_counter had to be excluded from the other skill levels. That was a little tricky, but it turned out to work just fine. Just thought I'd pass that along if you were interested.

| Return to the Quake Tutorial List | Return to the Main Page |

This site is designed for 800x600 resolution, and is best viewed in Netscape 4.0 or above with 16bit color or higher.

BSP is the sole creation of Yahn Bernier. I am only a dedicated user, reporting news and making tutorials so Yahn can spend more time enhancing BSP.

This web page was created and is being maintained by me (DeadMeat). Unless otherwise noted, all content appearing on this site was written by me. Also, 'DeadMeat's BSP Tutorials' were created entirely by me. All unauthorized use is prohibited. (c) 1997. So there :-P