Introduction
There was a scene (er, well it was like a scene) in Half-Life where an alien busts through a door. He didn't just bust through the door though. He pounded against it a few times first. Each time he pounded, the door would bulge out a little bit where, presumably, the alien's blows landed. It was a really cool effect and it's something that you can easily add to your own level.
How is it done?
The technique is actually pretty simple. The door is composed of three groups of (one of more) objects.
- The normal door
- The door bulges
- The broken door
Initially, the normal door is shown. Some event is needed to trigger stage two (ie: the player activates a trigger_once), then the door bulges start to appear, commonly accompanied by sounds of banging. After a certain amount of time, the door enters stage 3 (broken open), possibly accompanied by an explosion and debris.
Example
The example below takes you through this process in more detail. You will be creating a door that gets shot open by a group of grunts.
The first thing you do is create the control entities. In the picture below, the control entities are the two blue entities to the left of the door.
The first control entity is a
trigger_auto entity. The following values were set:
- Target ( target ) - "autostart"
- Delay before trigger ( delay ) - "0.5"
The second is a
multi_manager which has the following properties:
- Name ( targetname ) - "autostart"
- bulge1 (5) - toggles the first bulge on
- sound1 (5) - plays a gun shot sound
- bulge2 (6.5) - toggles the second bulge on
- sound1 (6.5) - plays a gun shot sound
- bulge3 (7) - toggles the third bulge on
- sound1 (7) - plays a gun shot sound
- door1 (8) - hides the "normal" door
- bulge1 (8) - turns the first bulge off
- bulge2 (8) - turns the second bulge off
- bulge3 (8) - turns the third bulge off
- door2 (8) - makes the "broken" door visible
- explosion1 (8) - triggers explosion and debris
In the multi_manager properties listed above, everything listed after the
Name property are key/delay pairs. The keys are the Name's of entities that will be created later in this example, and the delay values are the delays that will occur between when the multi_manager is activated and when the listed events will be triggered.
The above two entities automatically run through the door bending events with no interaction from the player. If you wanted the player to activate these events by walking through a trigger, you'd use a
trigger_once entity instead.
Now , as shown in the above picture, create the door. Select the door object and press
Ctrl+T
to turn it into a
func_wall_toggle entity. In the func_wall_toggle properties, set the
Name (
targetname ) to "door1".
Now we'll create the door's bulges (the one's that occur when the door gets hit by the gunfire). As shown in the picture above, each bulge is a six-sided spike. I've used the clipping tool to clip off the end of each spike. Create three spikes, turning each into a func_wall_toggle entity. In their properties, set their names to "bulge1", "bulge2", and "bulge3". Also, in each of their flag properties, enable the "Starts Invisible" flag.
It's not shown in this picture, but also create an
ambient_generic entity on the side of the door opposite the bulges. This sound will get played each time a bulge is created to simulate the gunfire. In it's properties, set the following values:
- Name ( targetname ) - "sound1"
- WAV Name ( message ) - "ambience/biggun3.wav"
In the ambient_generic flag properties, enable the "Large Radius", "Start Silent", and "Not Toggled" flags.
Now we've got another fairly simple task - creating the broken door. For the example map, I made a copy of the original door in the exact same place, then I clipped it into a number of pieces. Some of the pieces I then deleted, and others I clipped more to create a jagged opening.
Select all of the broken door pieces and press Ctrl+T to turn them into a func_wall_toggle entity. In the entity properties, set the
Name (
targetname ) to "door2". In the flag properties, enable the "Starts Invisible" flag.
Finally, we create the explosion and debris effects. In the above picture, there are 6 orange entities. The five outside ones are
env_shooter entities. All of them have the following properties.
- Name ( targetname ) - "explosion1"
- Model Name ( shootmodel ) - "models/metalplategibs.mdl"
- Material Sound ( shootsounds ) - Metal ("")
In addition, set the angle compass for the env_shooter entities so that they are aimed away from the door in the direction the explosion would shoot them (so, generally towards the player).
The middle of the six is an
env_explosion entity. Set it's
Name (
targetname ) to "explosion1". In the example map, I've also enabled the "No Damage" flag, but this is a matter of preference.
Last, throw some grunts behind the door. When the door sequence ends (with the gaping hole), they'll attack the player on sight, so be prepared.
Resources
Below is a list of entities related to this tutorial.
For a more concrete illustration, check out the example map linked below.
This article was originally published on the
Valve Editing Resource Collective (VERC).
TWHL only archives articles from defunct websites. For more information on TWHL's archiving efforts, please visit the
TWHL Archiving Project page.