Teleport With Effects Example

Half-Life HL
Teleport With Effects Example by Windawz
Posted 3 years ago2021-07-15 10:38:44 UTC • Examples • Half-Life
Loading...
Screenshot Thumbnail
Name
Teleport With Effects Example
By
Windawz Windawz
Type
Map
Engine
Goldsource
Game
Half-Life
Category
Examples
Included
RMF/VMF
Created
3 years ago2021-07-15 10:38:44 UTC
Updated
3 years ago2021-07-22 13:14:25 UTC
Views
2335
Downloads
455
Comments
2

Example of a teleporter with effects that occur on entering.
If you've got any questions, leave them in the comments or contact me by other means.

Features

On entering, the teleporter:
  • Plays a sound.
  • Activates a fade effect.
  • Telefrags anything in a volume around the destination.

Notes

  • The scientist can be used to test the telefrag feature.
  • The delays in the multi_managers may have to be tweaked for multiplayer to take latency into account.
  • The teleport in this example wasn't designed to work for monsters or pushables.

Included map sources

  • .rmf
  • .jmf

How to add an effect?

In case you don't know how to make the teleport do something new, like adding a sprite flash at the destination point, you should read this.

There are two triggers on top of the teleport pad: a trigger_teleport - the wider one, and a trigger_multiple - the taller one. If you look at the properties of the trigger_multiple, its Target field is set to tele_event.
Note!
You may and should replace the names of these entities in your maps to longer, more specific ones, especially if you're using several instances of this teleporter. It will help you avoid name clashes.
All you need to do is give the entity you want to be triggered whenever the teleport is entered the same name as the one in the trigger_multiple's Target field.
Removing effects
You're free to also remove the existing effects. But be careful - one of the default multi_manager's is used to trigger the teleport's multisource. You must not delete it nor the multisource, or the setup will not work properly.
For example, to add a sprite effect that flashes at the destination, you'll need:
  • A multi_manager.
  • An env_sprite.
First, you need to set up the env_sprite:
  1. Place the env_sprite at the destination spot.
  2. Open its properties.
  3. Give it a name and pick a sprite to use.
  4. Make sure you've set the FX Amount to a well-visible level and Render Mode to the desired mode.
Next, you'll have to configure your multi_manager:
  1. Give it a name.
  2. If you're using a Hammer-like editor, turn SmartEdit off.
  3. Add new field using one of the buttons on the right.
  4. Set the name of the field to the name of your env_sprite. Set the value to 0.
  5. Add another field, with the same name as the previous. Set the value to a delay in seconds - this will determine how long your sprite flash will last. I'd go with a value of 0.1 or 0.2.
  6. Turn SmartEdit back on.
Compile and run your map, then test the setup out. In case it doesn't work, double-check - you may have done something wrong along the way. If nothing helps, leave a comment or contact me by other means.

2 Comments

Commented 3 years ago2021-07-15 14:20:48 UTC Comment #103611
Thanks! It helped me to create the telefrag effect!
Commented 3 years ago2021-07-16 03:01:56 UTC Comment #103612
np man

You must log in to post a comment. You can login or register a new account.