This article's documentation is for anything that uses the Source engine. Click here for more information.

VortWarp

From Valve Developer Community
Jump to: navigation, search

VortWarp is a vertex shader available in all Source Source games since Half-Life 2: Episode One Half-Life 2: Episode One. It blends a Flowmap with a illumination mask, and creates a similar effect to how water uses Flowmaps in newer engine branches. The shader can be both used on brushes and models.

Icon-Bug.pngBug:Acts weirdly when lit by flashlight.

Shader parameters

$unlit <bool>
Whether or not the material should be lit.
$flowmap <texture>
Flowmap to use.
$entityorigin <vector>
The point which the model will be squished to. The entire model will try to be squished into that point. If unspecified becomes the world origin by default, "[0 0 0]".
Blank image.pngTodo: Test on brushes more. Test on world brushes, and on entity brushes. Do entities (ex. prop_static) and brushes have their $entityorigin centered by default, or again defaults to world origin?
$warpparam <float>
Warping amount toward the specified $entityorigin. 1.0 leaves the model unaffected, lower values squish more, while 0.0 makes it practically invisible. Does not accept values outside of that range.
$selfillummap <texture>
A $selfillummask to blend with the Flowmap.

Supported effects

Example

Example showing the minimal needed parameters in order to make the shader work.

VortWarp
{

	$basetexture	lights/white
	$flowmap	shadertest/cloud

	$selfillummap	shadertest/lump
	$selfillumtint	"{ 200 15 0 }"

	$warpparam	1.0

}

See also