Alien Teleport Effect (HL1): Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
m (Changed it to be more readable.)
mNo edit summary
 
(11 intermediate revisions by 6 users not shown)
Line 1: Line 1:
The Alien teleport effect is seen in varius places during [[Half-Life]]. It's however not used in Half-Life 2.
The Alien teleport effect is seen in various places during [[Half-Life]]. It's usually found in the form of a bright green particle explosion, followed by random beams of electricity and an alien spawning. It is commonly used to spawn enemies to surprise the player, or to bring in reinforcements.
The effect is often seen as a particle explosion with a lot of green beams coming out if and a spawning in monster is also often used with it.


To create the effect, first make a room in Hammer.
Although commonly used in Half-Life, it is not seen in [[Half-Life 2]], due to the effects of the resonance cascade being diminished.
Next create an [[env_sprite]] entity where you want the effect to be. Set the [[targetname]] keyvalue to whatever you want.
Set the sprites texture to something that looks good. Valve uses "sprites/f-explo" for most of it's teleport effects, however, other sprites like "sprites/a-tele" and other tele sprites will also look good. Set the scale to 1. Check the play once flag.


Next, place an [[env_beam]] in the same place as the sprite. Set the beams beam color to "0 0 255". Set the strike again time to -.5, and the sprite life time to .1 Check the following flags: Toggle, decal end and end spark. Name the beam whatever you want.
[[Blue_Shift|Half-Life: Blue Shift]] and [[Decay|Half-Life: Decay]] utilize an entity called [[env_warpball]] to create the sprites and beams. It is newer, from the Dreamcast and Playstation 2 ports of Half-Life. These last two games came out late enough to be built this way.


Next put a [[monstermaker]] in the floor under the sprite. Name it something. Set the amount of monsters, rate of spawning and max live Childrens to 1. Set the monster to spawn to the Alien you want to spawn. I recomend using [[monster_headcrab]], [[monster_houndeye]] or [[monster_alien_slave]].
== Tutorial ==
This tutorial will show how to set up the teleport effect. During this tutorial, the teleport effect as a whole will be refered to as "tele", and all entity targetnames will follow that template.


Next, create two [[ambient_generic]]s. Give them both the same name. Check the not toggled and start silent flags for bth of them. Set the sound for one of them to "debris/beamstart2.wav" and "debris/beamstart7.wav" for the other one.
To start with, make sure you have a map to put the teleport effect in. Make sure there is enough room for an alien of your choice to spawn.


Now, create a [[multi_manager]]. If you have smart-edit enabled, disable it. Add the following keyvalues to it.
=== Sprites ===
(env_sprite name) ; 0
[[File:Alien tele sprites.png|300px|thumbnail|right|<code>env_sprites</code> properly set up]]
(env_beam name) ; 0
The teleport effect uses two {{ent|env_sprite|engine=goldsrc}}. Start by creating an <code>env_sprite</code> about 56 units above the ground using the [[Hammer Entity Tool|entity tool]]. Name this sprite "tele_sprite_a". Set the ''Render Mode'' to "Glow", the ''FX Amount'' to "255" and ''Render FX'' to "Constant Glow". This will ensure that it renders in front of the spawned alien. Set the ''FX Color (R G B)'' value to "77 210 130". This will give it a green color. Set the ''Sprite Name'' to "sprites/Fexplo1.spr". Set the ''Scale'' to 1 if you're spawning in a medium sized alien, like an {{ent|monster_alien_slave|engine=goldsrc}}. You may want to set it smaller for smaller aliens like {{ent|monster_headcrab|engine=goldsrc}} or bigger for larger aliens like {{ent|monster_alien_grunt|engine=goldsrc}}.
(env_beam name) ; 1
Finally, go to the [[Flag|''Flag'']] tab and check the '''Play Once''' flag. This will cause the sprite's animation to only play once, rather than looping indefinitely.
(monstermaker name) ; 0
(ambient_generic name) ; 0
Now set a trigger or button to trigger your multi_manager.


There you go. Compile the map, and now you should see your effect appear with a teleporting in monster.
Now create a new sprite and set it up in the exact same way and place, except for a few differences. Set its name to "tele_sprite_b", the ''FX Color'' to "184 250 214" and the ''Sprite Name'' to "sprites/XFlare1.spr". Both of these sprites will be used for the final teleport effect.
 
You should now have two sprites in the same place that looks similar to the picture to the right. Feel free to tweak around with the values. For instance, if you are mapping for [[Half-Life: Opposing Force]] and want to spawn any of the Race X aliens, you should have your sprites set up with a purple color instead. Or you might want to use different sprites to better suit your situation.
 
=== Beams ===
One of the most defining traits of the Alien Teleport Effect is the beams of electricity that are randomly emitted from the teleportation orb.
 
Create an {{ent|env_beam|engine=goldsrc}} entity in the same place as your <code>env_sprites</code> and name it "tele_beams". Set the ''Start Entity'' to "tele_beams", ''Brightness'' to 150, ''Beam Color (R G B)'' to "197 243 169", ''Radius'' to 100, ''Life'' to ".5", ''Width of beam'' to "1.8", ''Amount of noise'' to "35", ''Sprite Name'' to "sprites/lgtning.spr", and ''Strike again time'' to "-.5".
 
Go to the ''Flags'' tab and check the '''Toggle''' and '''Random Strike''' flags. Make sure everything else is unchecked.
 
Once again, you may tweak these values to your liking. If you have a bigger scale for your sprites, it might be a good idea to increase the <code>env_beam's</code> ''radius'' value.
 
=== Sound ===
The Alien Teleport Effect wouldn't be the same without its characteristic sound of space being warped.
 
Create an {{ent|Ambient generic|engine=goldsrc}} at the same place as the <code>env_sprites</code> and <code>env_beam</code> and name it "tele_sound_a". Set the ''WAV Name'' to "debris/beamstart2.wav". Go to the ''Flags'' tab and check the '''Medium Radius''', '''Start Silent''' and '''Not Toggled''' flags. Make sure all the other flags are unchecked.
 
Next, create another <code>ambient_generic</code> in the same place and name it "tele_sound_b". Set the ''WAV Name'' to "debris/beamstart7.wav". Make sure all the same flags are checked as in the first <code>ambient_generic</code>.
 
=== Light ===
This one is optional, but recommended for enhanced atmosphere especially in dark areas.
 
Create a {{ent|light|engine=goldsrc}} entity in the same place as all the other entities, and name it "tele_light". Set the ''Brightness'' to "77 210 130 150". Next, set the ''Custom Appearance'' to "mmnmmommommnonmmonqnmmo". Finally, go to the ''Flags'' tab and check the '''Initially Dark''' flag.
 
=== Manager ===
This is where it all comes together, and all the previous entities are triggered in the right order.
 
Create a {{ent|multi_manager|engine=goldsrc}} somewhere near your effect entities and name it "tele_mm". Now, you have to turn off smart edit and input all of these values as shown below:
{| class="wikitable"
|-
! Key !! Value
|-
| tele_sound_a || 0
|-
| tele_sprite_a || 0
|-
| tele_sprite_b || 0
|-
| tele_light || 0
|-
| tele_beams || 0
|-
| tele_sound_b || 0.5
|-
| tele_light || 1
|-
| tele_beams || 1
|}
 
When the <code>multi_manager</code> is triggered, it will trigger all the entities listed within its values after the delays specified.
 
=== Spawner ===
[[File:Alien tele setup.png|300px|thumbnail|right|Full entity setup]]
Finally, we will create the actual spawner for the alien.
 
Create a {{ent|monstermaker|engine=goldsrc}} entity on the ground below your effect entities and name it "tele_spawner". Set the ''Target On Release'' to "tele_mm". Next, set the ''Monster Type'' to the type of alien you wanted to spawn. For instance, <code>[[monster_alien_slave]]</code>. Next, you can set up the ''Number of Monsters'' to whatever you want, but make sure the ''Max live children'' is 1, and ''Frequency'' is set to at least 1.
 
Now you can targetd the "tele_spawner" entity in any way you want, and it should work in game.
[[File:Alien tele game.png|600px|thumbnail|left|The teleport effect in-game]]
[[Category:Half-Life]]
[[Category:Half-Life Level Design]]
[[Category: Level Design]]
[[Category: Tutorials]]

Latest revision as of 00:02, 22 August 2024

The Alien teleport effect is seen in various places during Half-Life. It's usually found in the form of a bright green particle explosion, followed by random beams of electricity and an alien spawning. It is commonly used to spawn enemies to surprise the player, or to bring in reinforcements.

Although commonly used in Half-Life, it is not seen in Half-Life 2, due to the effects of the resonance cascade being diminished.

Half-Life: Blue Shift and Half-Life: Decay utilize an entity called env_warpball to create the sprites and beams. It is newer, from the Dreamcast and Playstation 2 ports of Half-Life. These last two games came out late enough to be built this way.

Tutorial

This tutorial will show how to set up the teleport effect. During this tutorial, the teleport effect as a whole will be refered to as "tele", and all entity targetnames will follow that template.

To start with, make sure you have a map to put the teleport effect in. Make sure there is enough room for an alien of your choice to spawn.

Sprites

env_sprites properly set up

The teleport effect uses two env_sprite. Start by creating an env_sprite about 56 units above the ground using the entity tool. Name this sprite "tele_sprite_a". Set the Render Mode to "Glow", the FX Amount to "255" and Render FX to "Constant Glow". This will ensure that it renders in front of the spawned alien. Set the FX Color (R G B) value to "77 210 130". This will give it a green color. Set the Sprite Name to "sprites/Fexplo1.spr". Set the Scale to 1 if you're spawning in a medium sized alien, like an monster_alien_slave. You may want to set it smaller for smaller aliens like monster_headcrab or bigger for larger aliens like monster_alien_grunt. Finally, go to the Flag tab and check the Play Once flag. This will cause the sprite's animation to only play once, rather than looping indefinitely.

Now create a new sprite and set it up in the exact same way and place, except for a few differences. Set its name to "tele_sprite_b", the FX Color to "184 250 214" and the Sprite Name to "sprites/XFlare1.spr". Both of these sprites will be used for the final teleport effect.

You should now have two sprites in the same place that looks similar to the picture to the right. Feel free to tweak around with the values. For instance, if you are mapping for Half-Life: Opposing Force and want to spawn any of the Race X aliens, you should have your sprites set up with a purple color instead. Or you might want to use different sprites to better suit your situation.

Beams

One of the most defining traits of the Alien Teleport Effect is the beams of electricity that are randomly emitted from the teleportation orb.

Create an env_beam entity in the same place as your env_sprites and name it "tele_beams". Set the Start Entity to "tele_beams", Brightness to 150, Beam Color (R G B) to "197 243 169", Radius to 100, Life to ".5", Width of beam to "1.8", Amount of noise to "35", Sprite Name to "sprites/lgtning.spr", and Strike again time to "-.5".

Go to the Flags tab and check the Toggle and Random Strike flags. Make sure everything else is unchecked.

Once again, you may tweak these values to your liking. If you have a bigger scale for your sprites, it might be a good idea to increase the env_beam's radius value.

Sound

The Alien Teleport Effect wouldn't be the same without its characteristic sound of space being warped.

Create an Ambient generic at the same place as the env_sprites and env_beam and name it "tele_sound_a". Set the WAV Name to "debris/beamstart2.wav". Go to the Flags tab and check the Medium Radius, Start Silent and Not Toggled flags. Make sure all the other flags are unchecked.

Next, create another ambient_generic in the same place and name it "tele_sound_b". Set the WAV Name to "debris/beamstart7.wav". Make sure all the same flags are checked as in the first ambient_generic.

Light

This one is optional, but recommended for enhanced atmosphere especially in dark areas.

Create a light entity in the same place as all the other entities, and name it "tele_light". Set the Brightness to "77 210 130 150". Next, set the Custom Appearance to "mmnmmommommnonmmonqnmmo". Finally, go to the Flags tab and check the Initially Dark flag.

Manager

This is where it all comes together, and all the previous entities are triggered in the right order.

Create a multi_manager somewhere near your effect entities and name it "tele_mm". Now, you have to turn off smart edit and input all of these values as shown below:

Key Value
tele_sound_a 0
tele_sprite_a 0
tele_sprite_b 0
tele_light 0
tele_beams 0
tele_sound_b 0.5
tele_light 1
tele_beams 1

When the multi_manager is triggered, it will trigger all the entities listed within its values after the delays specified.

Spawner

Full entity setup

Finally, we will create the actual spawner for the alien.

Create a monstermaker entity on the ground below your effect entities and name it "tele_spawner". Set the Target On Release to "tele_mm". Next, set the Monster Type to the type of alien you wanted to spawn. For instance, monster_alien_slave. Next, you can set up the Number of Monsters to whatever you want, but make sure the Max live children is 1, and Frequency is set to at least 1.

Now you can targetd the "tele_spawner" entity in any way you want, and it should work in game.

The teleport effect in-game