Tutorial: Water Last edited 1 year ago2022-09-01 13:03:49 UTC

✔️ Download example map

This is a tutorial about how to use water textures and water in the Half-Life engine. There are many ways water can be used in a Half-life map. Just so you can test how water will work before putting it into a map of yours begin by making a new RMF.

Make a room or beachhead as I have. If you made a room make a sink, pool or toilet in it. First we will select the texture(s) that we will be using for our water (make sure liquids.wad is a texture wad you have active).

Go to the texture browser and type in ! as your filter text. Some water textures will come up. You can tell if a texture is a water texture if it has ! in front of it (as in '+' for lightable objects and { for decals).
Liquid textures start with excitement!Liquid textures start with excitement!
Once you have your texture picked out you should make a brush with it were you want your water to be. Now save and compile your map. Check out the water in the game. That wasn't very good now was it? There are several things you can do to make this water look better:

If your video card is compatible with OpenGL and you aren't already running with it do so now, you'll thank me later. Now with OpenGL mode on you can edit the height of waves that you can create using a brush entity called func_water. This entity sort of acts like a door that continually is moving in different ways.

Ok back to the waves. If you tie your ! textured brush to a func_water and go to its object properties you will see a lot of keys representing a door. Start by scrolling to the bottom of this list until you find a key called Wave Height.

Enter the height of the waves you want. I'm not sure how these heights are measured so just use a number like 10 to start then experiment with the height until you reach the desired height. I think it is based on one peak of wave form, ie: 5 will give you a wave top to wave bottom of 10 units. The worldspawn entity can also be used to set default wave heights, but the actual entity value will override that.
Water and Waves? Who would've thought.Water and Waves? Who would've thought.
Now run the map. Look any better? For those of us running on software (like me :) ) that doesn't look any better. Don't give up, there is something else you can do.

Set the transparency level! this is done exactly as its done for a func_wall with a glass texture. In the object properties go to Render Mode and set it to Texture. Then set the FX Amount to a number between 1-255. I use about 120-30 for a good effect. Now compile the map and look at your beautiful water?

But wait, there's more! Go back to your object properties for the func_water and there is a key called Contents. It can be used to set your func_water brush to act as lava, slime or good ol' H2O.

Using water, large expanses of water will push the r_speeds up. This is because the water texture is small. Stretching water textures makes it look really odd. The functionality of a block of water affects the way the map is rendered, and can cause lag. Just keep these in mind when you are making your map.

6 Comments

Commented 15 years ago2008-12-19 23:37:22 UTC Comment #100650
Here's one hint about water i learned:

Problem:
If you have a big "pool" of func_water made out of many brushes and after compile many top faces of the water randomly won't show up.

Fix:
Instead of making all the brushes of the pool a single func_water, make each seperate brush it's own func_water, and this should eliminate the disappearing face error.
Commented 13 years ago2010-08-06 15:15:52 UTC Comment #100651
Is it possible to incorparate this into source ?
Commented 13 years ago2010-10-22 01:58:38 UTC Comment #100652
How do you make healing water found in Xen?
Commented 13 years ago2011-01-02 20:48:22 UTC Comment #100653
to make healing water you use a trigger_hurt with a -damage value (-2 dmg = +2 hp a sec)
Commented 9 years ago2014-11-04 03:58:03 UTC Comment #100657
I need damaging water for my radiation leak, anybody know how to use the trigger_hurt to make one of those damaging water?
Commented 8 years ago2015-05-30 16:41:42 UTC Comment #100658
I have a question. I'm trying to make a map that floods from the start of each CS 1.6 round to the end. When the round restarts I want the process to restart. I can get it to slowly flood at the beginning of the round however, it will only go down slowly during the second round and so on. Is there a way to reset this entity to a point of origin every round? Or maybe use a different entity or something? Any ideas are appreciated.

You must log in to post a comment. You can login or register a new account.