Portal 2

Portal 2

Not enough ratings
p0rtalmaster's Hammer Guide Series Part 16/19
By The Sojourner
Hello and welcome to part 16/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.
   
Award
Favorite
Favorited
Unfavorite
A Long Lost Testing Element
We all think it should've been included somewhere in Portal 2's puzzles, and yet it wasn't. It showed up in those old E3 Demo videos, and yet its promise was broken. It appeared in some workshop maps, but was it enough? I'm talking about...
The Pneumatic Diversity Vent


This will be a somewhat shorter guide than the rest of them, as it's focusing on just one testing element without a lot of variation. The Pneumatic Diversity Vent is known for sucking things like cubes and turrets (but not test subjects — unless you really want to) away to deadly places such as the incinerator.

The key entity to making the Pneumatic Diversity Vent work is point_push. It may just look like a little greenish box in Hammer, but it's more than that. It has a radius (similar to sound entities, lights, and placement helpers) which, when entered, will suck things into or blow things away from its point. To suck, all you need to do is set the Magnitude keyvalue to a negative number, and to blow, just use a positive number. As you want the point_push to only affect test objects, you'll need to uncheck the "Push players" flag.

Additional helper entities, especially for when these things suck rather than blow, are our old friends trigger_catapult and trigger_push. Be sure to check the flags to ensure that only cubes, turrets, other test objects, and basically anything that is not a test subject gets affected.

And the rest is just details: prop_statics, clipping brushes as needed, an info_particle_system set to broken_tube_suck for the dust effect at the Pneumatic Diversity Vent's entrance, and an ambient_generic set to Tube.Suction for the sound effect (and please do not use the old sound that was designed for Portal — this is not Portal 1 anymore).

Rounding out the list of entities, we have:
  • At least two prop_statics (try pulling some world models from models/props_bts/vactube_*; there are also a few in the models/props_backstage folder)
  • A point_push
  • Some trigger_pushes
  • A trigger_catapult for launching the objects up hard into the vent (and away from the point_push)
  • An info_particle_system set to broken_tube_suck (face it down)
  • An ambient_generic set to Tube.Suction (please do not use the old sound that was designed for Portal — this is not Portal 1 anymore)
  • A trigger_multiple set to kill whatever touches it (use !activator as a targetname, as you did when creating deadly goo)
  • Clipping brushes as needed
  • An info_placement_helper at the bottom of your vent (set "Radius" to "80" and "Force Placement" to "Yes")

Although they may vary slightly, here are some good base settings to try for the sucking stuff:
  • point_push: a radius of 330, magnitude of -55 (for fine-tuning, the BEEMOD instance uses a second point_push with a radius of approx. 220, magnitude of -5, so as to make the pull slightly stronger as things get closer)
  • trigger_catapult: 64×64 units with the height being from the ground up to your entrance, Launch direction should be up into the entrance, Physics Object Speed is 800-900
  • trigger_pushes:
    • For the one surrounding the entrance: approx. 128 units off of all sides from the entrance, Launch direction should be down, Speed is 500
    • For the one inside of the entrance: 64×64 units, Launch direction should be up, Speed is 1500
    • For the others: Launch direction should be in the direction you intend it to go, Speed is 1500 or so

NB Pneumatic Diversity Vents are most effective when they are 128-192 units (1-1½ voxels in the in-game editor) off of the floor. Also, if things ever look weird during testing, try tweaking these settings and the positioning of these sucking entities until it looks plausible.

The process of installation is as follows:



1) Create a hole in your test chamber for the Pneumatic Diversity Vent to go (ideally some hidden "behind-the-scenes" area).

2) Place the prop_statics in their locations.

3) Place the clipping brushes and trigger_pushes in their locations.

4) At the back end of the Pneumatic Diversity Vent, place your trigger_multiple.

5) At the front end of the Pneumatic Diversity Vent, place your trigger_catapult and point_push.

6) At the front end of the Pneumatic Diversity Vent, place your ambient_generic and info_particle_system.

7) On the portalable surface at the bottom of your Pneumatic Diversity Vent, place your info_placement_helper.

Another use for these things is transporting stuff (test subjects and test objects alike) to a different location, in which case the flags will need to be set on the triggers and point_push accordingly. Also, at the end, instead of a "kill" trigger, we'll just have an exit. To make things go more smoothly for the test subject, you can use the game_ui or point_viewcontrol entities to disable movement while the test subject is inside the Pneumatic Diversity Vent.

Now go forth and suck!
Flow Control
As always, Aperture Science allows the option to control any testing element that is usable in a test chamber, and that includes the one you're working with. Any output device should work OK with these. Enabling and Disabling should be very simple: just enable and disable the following (preferably via a logic_branch):
  • ambient_generic (use the PlaySound and StopSound inputs)
  • info_particle_system (use the Start and Stop inputs)
  • trigger_catapult
  • point_push
  • NOT the trigger_pushes, as anything still in the vents will need to be carried away.
NB as noted on the VDC Wiki, enabling and disabling an ambient_generic can be buggy. It needs to loop its sound, but if it starts enabled, it cannot be controlled. The solution involves starting the ambient_generic DISabled and pre-enabling it with a logic_auto.
Additional Effects
Aperture Science Passive Vital Apparatus Vent Monitor

If you've decided to use the model models\props_backstage\vacum_scanner_tv.mdl (or the vertical variation) on your Pneumatic Diversity Vent, you can use a couple of trigger_multiples at the entrance, each filtered out specifically for cubes (prop_weighted_cube) and turrets (npc_portal_turret_floor). Each one will be set to change the skin of the model you're using accordingly. Check out this page on the VDC Wiki on filtering for more information. At a minimum for getting fancy, you'll need filter_activator_class, and you may need filter_activator_model as well. These can be used together via a filter_multi.

Those Little Lights Again...

For an additional effect on whether or not a Pneumatic Diversity Vent is active or not, you can use some env_sprites (two sets, one for "off" and one for "on") with the same settings as you used for making breakers (re-read the previous guide if you don't remember the settings). These can be controlled in addition to the 4 entities listed in the previous section via the ToggleSprite output (or HideSprite and ShowSprite).
Meanwhile, Behind-the-Scenes...


Aperture Science's Pneumatic Diversity Vents can be seen all over the scenes here. Valve used special models and special animations to make all those cubes, turrets and whatnot do their thing, but the rest of us without that sort of modeling power have a couple of options:

1) Make some cubes and turrets and other things and use trigger_pushes to move everything along. The disadvantage is that this method can be noisy (perhaps painfully so). But then again these things are naturally noisy, and so this is the more plausible method.

2) Make some cubes and turrets and other things and get them moving along a fixed path (set by path_tracks). The disadvantage of this method is that it looks too tame in comparison to the previous method. This is not Portal 1 anymore, folks! We wanna see stuff ricocheting off of the sides and all. That is part of the reason why the game's developers made all those special model animations.
More Information
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 16/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 testing elements behind-the-scenes)
Next Guide (about about auto-portals and the rotating portal gun)

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!

4 Comments
Beckeroo 😎👍 Jun 10, 2023 @ 6:41am 
Hammer addons for Portal 2 includes an entity for vactubes.
Lemmy Jul 31, 2021 @ 9:38am 
According to another guide I read the other day, adding two func-rotatings and parenting the object to the first one and the first one to the second one
I think
I'm probably wrong lol
MechanicMind01 Apr 22, 2021 @ 6:45am 
I love these tubes; they're my favorite part of the Aperture Science facility. Besides the catwalks, though, of course.
totes amaze balls Apr 17, 2018 @ 4:04am 
Someone should make a guide on making those custom vac tubes with things in them. The new way that is... Ya know with the tanktrains and such.