Portal 2 Guide

p0rtalmaster's Hammer Guide Series Part 10/19 for Portal 2

p0rtalmaster’s Hammer Guide Series Part 10/19

Overview

Hello and welcome to part 10/19 of my series of mini-guides, designed to help you learn perhaps what is the biggest part of the Portal 2 Authoring tools: Hammer.For a super-quick version of this series, please check out my other guide, Hammer for the Flustered.

Intro

This guide covers death — to cubes, turrets, and test subjects, in the form of getting fizzled, laser-burned, and drowned. Also, could you jump into that deadly pit for me while you’re at it?

Fizzlers and Laserfields

This next test involves emancipation grills. Remember? I told you about them in the last test area, that did not have one.
~ GLaDOS

Creating a fizzler is easy — sometimes too easy. The proper recipe for one requires THREE (not one!) brushes for EACH fizzler (not one brush for multiple fizzlers!): two for the sides and one for the center (only 128×128 fizzlers are an exception). It also requires two logic_relays (for enable/disable) and the relevant prop_dynamics (models/props/fizzler_dynamic.mdl for the sides/emitters) if the fizzler is going to be switched on/off. prop_statics (models/props/fizzler.mdl for the sides/emitters) are otherwise needed.

First, each fizzler or laserfield needs some surrounding material:

The dimensions of each of the fizzler brushes are:

  • 128 units high (use multiple fizzlers for dimensions higher than 128)
  • 64 units long for the edges, with the remainder of the gap being take up by the center brush
  • 2 units thick

Exceptionally, 128×128 fizzlers only need one brush, with the broad faces textured with effects/fizzler.

The dimensions of the laserfield/trigger_hurt brushes, which will share the exact same location, are:

  • The height of your laserfield (a multiple of 128)
  • The width of your laserfield
  • 2 units thick

1) Texture the three fizzler brushes accordingly (see below for details).

2) Select the three fizzler brushes and tie them to the same entity: trigger_portal_cleanser. Set the “Visible” keyvalue to “Yes.”

3) Duplicate your fizzler sides as needed and name them all the same thing (yes, this is a group).

4) Duplicate the fizzler brushes as needed and name them all the same thing (another group).

5) On each of the logic_relays, set these I/O:

Now all you have to do is trigger each of the logic_relays for every enable/disable that the fizzler does. For static fizzlers, use a prop_static with models/props/fizzler.mdl instead and skip the logic_relays and I/O.

The creation for laserfields is almost identical, but instead of the three brushes for a trigger_portal_cleanser, you’ll only need two brushes: a trigger_hurt and a laserfield brush. This even applies for multiple-level laserfields. The model used for the side/emitter props is identical, with the skin set to 2.

1) Texture the laserfield brush accordingly (see below for details).

2) Make the laserfield texture a func_brush and give it a name, so that it can be enabled/disabled. Set its solidity to “Never Solid” and “Disable shadows” to “Yes.”

3) Make the trigger_hurt of identical size to the laserfield brush, texture it with the trigger (tools/toolstrigger) texture, and set these properties:

4) Duplicate your laserfield sides as needed and name them all the same thing.

5) On each of the logic_relays, set these I/O:

Again, for static laserfields, use a prop_static with models/props/fizzler.mdl (set skin to 2) instead and skip the logic_relays and I/O.

Some Texture Alignment Tips

It is here more than anywhere else, that texture alignment of the fizzlers and laserfields is critical. Start off by creating some nodraw blocks — only the broad faces will be retextured with the fizzler/laserfield textures.

To best align the fizzler textures, set your side brushes to 128 units high, 64 units long, and 2 units thick. Apply the effects/fizzler_l or effects/fizzler_r to the broad faces as needed, and using the Face Edit tool, click the “Fit” button. Do the same for the center brush (use the texture effects/fizzler_center). Now all you have to do is turn it into a trigger_portal_cleanser and copypasta.

For laserfields, it’s usually best to start with a brush that’s 128 units high and 2 units thick. Apply the effects/laserplane texture to the broad faces and using the Face Edit tool, click the “Fit” button. Because Valve screwed up the laserfield texture somewhat, you’ll also need to shift the texture up (Y direction) by 256 units. Now you can stretch the brush up/down as needed.

If anything still looks weird (i.e. misaligned), there are other justification alignment options you can try. Most likely this won’t be the case.

Lastly, a few important dos and don’ts:

Also please don’t just use the three brushes (or worse yet just one) for multiple fizzlers, as they flash separately when a portal shot hits it. We’re watching you!

Deadly Goo/Slime Water/Toxic Acid/etc.

As you can probably tell, this well-known testing element goes by many names. Its main purpose is to serve as a hazardous “moat” area — one in which anything and everything will die. This is also one of the few testing elements that can be made entirely out of brushes.

1) Create a little pit for your deadly zone, at least 256 units deep. Texture the bottom with tools/toolsblack_noportal.

2) Create a brush with a water texture on it, which is going to be used to fill your pit. Although Valve made many of the Portal 2 water textures specific to their maps, that doesn’t mean that one or more might fit in yours. Experimentation is key here (and perhaps just knowing the textures). Many of the textures are found in the nature directory, beginning with toxicslime.

3) At the bottom, create a trigger_multiple, 128 units high or shorter. Uncheck the “clients” flag and check the “physics objects” flag. Set it to output:

4) Covering the same area as the water brush but slightly shorter, create a trigger_hurt with these settings:

NB For those ubiquitous semi-convex pits, multiple brushes are going to be needed, but ultimately they are all going to act as one. For the water brush, nodraw is your friend: use it where edges meet to avoid any weirdness.

Bottomless Pits

Not exactly standard, but still used in certain places of Aperture Laboratories. They function exactly like a deadly goo pit, but are designed for special themes. Creation is identical to the deadly goo pits, except that your pit will be a lot deeper than before, and that no water texture is needed. The triggers will also be somewhat relocated as well.

One difference between the deadly goo and bottomless pits (at least in singleplayer maps) is the fade. Partway down before the player dies, the screen will fade to black. This effect is accomplished by using a trigger_multiple at the start of the moat area and an env_fade.

Settings for the env_fade:

With the env_fade, you’ll also need to check off the “Triggering player only” and “Stay Out” flags.

Output for the trigger:

Mistakes to Avoid & More Information

  • Incorrect texture alignment of fizzler and laserfield textures. TEXTURE ALIGNMENT OF THESE TWO THINGS IS MORE CRITICAL THAN ANY OTHER TEXTURE ALIGNMENT. It simply cannot be emphasized enough.
  • Incorrect use of fizzlers. Remember, they not only need to look right, but act right. They need to flash individually.
  • Not carving out a hole for the fizzler/laserfield sides. Even Valve has been guilty of this, so don’t feel bad with this one. It’s a more subtle mistake, but one that if you fix, your map will look better.
  • Not sealing the bottom of deadly goo pits with something visible. Even a black (tools/toolsblack_noportal) texture will do.
  • Allowing players to portal into bottomless pits. Thankfully I haven’t seen this mistake in a while.
  • One more subtle error: forgetting the fade (env_fade) for bottomless pits, especially shallow ones.

More information from the VDC Wiki:

Master Guide List

Please note that there are still some works in progress. This section will be updated as I finish more guides for you!

You are currently viewing part 10/19 in the series.

| 00 | 01 | 02 | 03 | 04 | 05 | 06 | 07 | 08 | 09 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 |

Previous Guide (about various standard testing elements)
Next Guide (miscellaneous useful stuff)

Please feel free to leave a well-reasoned question or comment below. Either I or a qualified Test Chamber Associate (you’ll know because they make all the good maps on the workshop) will respond. If your question or comment is not well-reasoned, I recommend reading over my guides again until you understand them 100%. No further information is required here or will be provided, and you will become an excellent Test Chamber Designer — using Hammer!

SteamSolo.com