Gordon Freeman is back! HalfLife 2 picks up some time after the original Half-Life left off, with Gordon Freeman working for the G-Man. Along with scientist Eli Vance and his daughter Alyx, your mission is to... well, that would be telling.

Report this article Adding Precipitation

Learn how to add rain, snow, or falling ash into your Half-Life 2 map.

Posted by Psalm on Jul 24th, 2007 digg this super bookmark
Intermediate Mapping/Technical.


In this tutorial, you will use brush based entities to add precipitation to your map, either rain, snow, or falling ash. This is a relatively simple process, but this tutorial assumes intermediate skill in Hammer.

Create a basic map of any size.
Tutorial Image
Using brushes, create a simple structure in the center of the map. This will be a shelter from the precipitation.
Tutorial Image
Next, create a brush textured with “tools/toolsinvisible” covering the entire top half of the map, stopping at the roof of the structure. (A skybox wall in the picture is cut away)
Tutorial Image
Using the clip tool, section off the brush and drag the portions down so that the invisible brush covers the entire map, except for underneath the structure.
Tutorial Image
Tutorial Image
Tutorial Image
It may look awkward, but it’s ok if the brushes overlap a bit.
Tutorial Image

Control+click to select all of the invisible brushes and tie them (control+T) to a func_precipitation entity.
Tutorial Image
They will now become boxes in which the precipitation will fall. It’s important to note that the precipitation will not fall FROM the boxes, it will fall IN the boxes. Select which kind of precipitation you want under the “Precipitation Type” box.

With all of the brushes still selected, make them hollow with Control+H and enter 2 as how thick you want the walls. Remember, it’s ok if they overlap.

Add an “info_player_start” and test the map.
Tutorial Image
If you’re doing snow or ash, you’re finished. If you’re doing rain, you’re almost done. The last thing to do is add an ambient sound, because it looks a bit strange to see rain and not hear it.

Create an “ambient_generic” somewhere on the map. Name it “RainSound”, and select the “Play Everywhere” flag. All other flags should be unchecked. You also have to set the “Sound Name” property. I like ambient/levels/canals/dam_water_loop2.wav for heavy rain, but you can choose a different sound if you want.
Tutorial Image

You’re done! Precipitation is a great mood setter when used sparingly. I’d recommend using an “env_fog_controller” for heavy rain to make it look a bit better.

For questions or feedback, you can email (hambandito@gmail.com) or PM me.

Comments
Varsity
Varsity Jul 29 2007, 3:05pm says:

A soundscape is far more useful than an ambient_generic, unless your map is entirely outdoors and the rain sound never changes.

I don't understand why you hollow the brushes? You'd want rainfall in the middle of the brush too! :)

+1 vote     reply to comment
Psalm
Psalm Jul 30 2007, 3:01pm says:

It's just always worked better for me that way. Even if the brushes are hollowed, the precipitation still falls inside the box.
Yes, a soundscape would be better, but they are much more complicated.

+1 vote     reply to comment
UltraElite
UltraElite Aug 6 2007, 10:07am says:

Hi,
i was wondering how did you get the grass on the floor of the map?
If its an Entity could you tell me which one and which type of grass you used.
Thanks

+1 vote     reply to comment
Psalm
Psalm Aug 10 2007, 9:39am says:

The grass sprites come with many of the grass textures, but they only show up when you run the map. I've used nature/blenddirtgrass001.

+1 vote     reply to comment
UltraElite
UltraElite Aug 10 2007, 3:42pm says:

Thanks Psalm.

+1 vote     reply to comment
mctusk
mctusk Oct 29 2007, 8:14am says:

Nice Tut!

+1 vote     reply to comment
Null-Entity
Null-Entity May 8 2008, 3:25am says:

Ok I must be a complete noob but I couldnt get it to work.. I even simplified it..

Hollow box level, player start point,box for precipitation with invisible texture and CTRL+T precipitation to it.. I have an empty box level with nothing but me in it :S

+1 vote     reply to comment
Post a Comment

Only registered members can share their thoughts. So come on! Join the Mod DB community today (totally free) and do things you never thought possible.

Icon
Half-Life 2
Platforms
PC, X360, PS3, XBOX
Developer & Publisher
Valve
Engine
Source
Contact
Send Message
Official Page
Valvesoftware.com
Release Date
Released Nov 10, 2004
Game Watch
Track this game
Bookmark
Digg Super bookmark
Tutorial
Related Games
Half-Life 2
Half-Life 2
Single & Multiplayer First Person Shooter