Download attachment
"Beam me up Scotty!"
Teleportation, wouldn't that be cool. No more driving, just enter your destination and away you go. It is not available in real life, but it is in game development. Adding teleportation is an easy accomplishment in Half-Life, which has many uses. Things get more complex when adding
triggers,
multisource's, and
multi_manager's for effects.
This tutorial assumes you know the basics of Hammer or World Craft. Making
brushes, assigning them to an entity, and creating entities. Other than that, I am attempting to be as detailed as possible, so new Mappers can follow along.
Its Simplest Form:
Teleporting requires a minimum of two entities,
trigger_teleport and
info_teleport_destination. The trigger_teleport entity is a brushed based entity, which is where the player is being teleported from; info_teleport_destination is the player's destination.
As stated before, trigger_teleport is a brush-based entity. So, make a brush where the teleporter is to be and tie it to the trigger_teleport entity. The only thing that must be set is the Target, which is the name you plan on giving info_teleport_destination; I used
tele_dest1.
Now, use the
Entity Tool to place the info_teleport_destination where you want the player to end up. Be careful not to place the entity too close to any brushes. It would be a shame to stick the player into a wall, desk, or other solid form. Set its name to match the Target you gave to trigger_teleport; again, I used
tele_dest1. Now you have a working teleporter.
Note: The player cannot see a trigger_teleport, which is handy if you want him to be teleported without forewarning. But, if you want the player to know he is going to be teleported you will have to create a visible teleporter. Try adding a sprite, by checking out
Tutorial: Using Sprites.
Switch Activated:
Now to add a little bit of complexity to teleportation, by controlling the teleporter through a switch. Here we will turn the "machine" on and give the player five seconds to use it before it deactivates.
Create your entities as above and add a
multisource and
func_button to your map. Set the values as follows:
trigger-teleportName:
tele_trig1Target:
tele_dest2Master:
tele_masterinfo_teleport_destinationName:
tele_dest2func_buttonTarget:
tele_masterDelay Before Reset: 5Flags:
Don't MovemultisourceName:
tele_masterTarget:
tele_trig1The names used above are those I used in the example map, like everything else you can use your own; just be sure they correspond with one another. Compile the map and you have a triggered teleporter.
Teleporter
Final Words:
Half-Life gives you the tools to come up with creative ways to initialize your teleporters. With some experimentation and imagination, how your machine is initialized and where your player goes has unlimited possibilities. Ambience, lasers, sparks, and other features can be added and manipulated with the use of multisource and muti_managers. Eventually, I will update the example map to demonstrate this, but till then combine other tutorials and play around.
Happy Mapping!