Vlatitude Archive: HL2 - Water Last edited 4 years ago2019-04-25 02:41:42 UTC

You are viewing an older revision of this wiki page. The current revision may be more detailed and up-to-date. Click here to see the current revision of this page.

This article was recovered from an archive and needs to be reviewed

The formatting may be incorrect as it was automatically converted to WikiCode from HTML, it needs to be revised and reformatted.

Normal Water

Water in hl2 is a little illogical to make, but following these steps isn�t: Some rather strange rules apply to water in HL2:

Rising Water

To create rising water, you should break the first rule: Tie all brushes representing water (made like explained above) you would like to rise to a func_water_analog. It has a few properties to fiddle with, here they are:

The only properties you need to fiddle with to make this work, are in bold. All the other properties work on default (but can be changed if necessary). To make the water rise, target it with the "Open"-input, and to make it go down again target it with the "Close"-input

PROPERTIES

Name targetname: The name that other entities refer to this entity by.

Parent parentname: The name of this entity's parent in the movement hierarchy. Entities with parents move with their parent.

Origin (X Y Z): The position of this entity's center

Move Direction (Pitch Yaw Roll): The direction the water will move, when its "open" input is triggered normally you would make it target upwards

Start Position: Position of the water brush when spawned. The range is a value between 0.0 and 1.0, where 0 is the starting position and 1 is the starting position + (move direction * move distance).

Speed: The speed that the water brush moves, in inches per second.

Move Distance: The distance from the starting point that the water brush should move, in inches.

Sound played when the water brush starts moving.

Sound played when the water brush stops moving.

Wave Height: height of the waves.

INPUTS

Kill: Removes this entity from the world.

KillHierarchy: Removes this entity and all its children from the world.

AddOutput: Adds an entity I/O connection to this entity. Format

FireUser1: Causes this entity's OnUser1 output to be fired.

FireUser2: Causes this entity's OnUser2 output to be fired.

FireUser3: Causes this entity's OnUser3 output to be fired.

FireUser4: Causes this entity's OnUser4 output to be fired.

SetParent: Changes the entity's parent in the movement hierarchy.

SetParentAttachment: Change this entity to attach to a specific attachment point on it's parent. Entities must be parented before being sent this input. The parameter passed in should be the name of the attachment.

ClearParent: Removes this entity from the movement hierarchy, leaving it free to move independently.

Open: Move the water brush to the end position (starting position + (move direction * move distance)).

Close: Move the water brush to the starting position.

SetPosition: Move the water brush to a specific position between 0.0 and 1.0, where 0 is the starting position and 1 is the starting position + (move direction * move distance).

OUTPUTS

OnUser1: Fired in response to FireUser1 input.

OnUser2: Fired in response to FireUser2 input.

OnUser3: Fired in response to FireUser3 input.

OnUser4: Fired in response to FireUser4 input.

OnFullyOpen: Fired when the water brush reaches the end position (starting position + (move direction * move distance)).

OnFullyClosed: Fired when the water brush reaches the starting position.

One small note is, that this entity isn't bug-free: bugs may appear when you are in the water and are able to look at the sky. Also not everything that floats in normal water floats in this water. Just be warned.

Example map: none

By Zombie@computer (Link: mailer.php?uid=16)

Printer Friendly Version (Link: print_tutorial.php?tutID=60)
User posted image
This article was originally published on 69th Vlatitude.
TWHL only archives articles from defunct websites. For more information on TWHL's archiving efforts, please visit the TWHL Archiving Project page.

Comments

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