Info overlay: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
m (clarified render order description slightly)
m (Updated keyvalues)
Line 16: Line 16:


== Keyvalues ==
== Keyvalues ==
*'''material'''
{{KV|Name|targetname|Name of the overlay. Used to access the overlay with an [[env_texturetoggle]].}}
:The [[material]] to overlay.
{{KV|Material|material|The [[material]] to overlay.}}
*'''sides'''
{{KV|Brush faces|sidelist|Faces on which the overlay will be applied.}}
:(sidelist) Faces on which the overlay will be applied.
{{KV|RenderOrder|integer|Higher values render after lower values (on top). This value can be 0–3.}}
*'''RenderOrder'''
{{KV|U Start, U End, V Start, V End|float|Texture coordinates}}
:(integer) Higher values render after lower values (on top). This value can be 0–3.
{{KV|Overlay Basis Origin (Read-Only)|Vector}}
*'''StartU''', '''EndU''', '''StartV''', '''EndV'''
{{KV|Overlay Basis U (Read-Only)|Vector}}
:(float) Texture coordinates
{{KV|Overlay Basis V (Read-Only)|Vector}}
*'''BasisOrigin'''
{{KV|Overlay Basis Normal (Read-Only)|Vector}}
:(Vector) Overlay Basis Origin (Read-Only)
{{KV|Start Fade Dist|float|Distance at which the overlay starts to fade (<0 = use fademaxdist).}}
*'''BasisU'''
{{KV|End Fade Dist|float|Maximum distance at which the overlay is visible (0 = don't fade out).}}
:(Vector) Overlay Basis U (Read-Only)
*'''BasisV'''
:(Vector) Overlay Basis V (Read-Only)
*'''BasisNormal'''
:(Vector) Overlay Basis Normal (Read-Only)
*'''uv0''', '''uv1''', '''uv2''', '''uv3'''
:(vector) Overlay Points (Read-Only)

Revision as of 05:56, 8 May 2011

Template:Point ent

Entity description

The info_overlay entity is automatically placed when you use the Hammer Overlay Tool. The sides keyvalue is automatically set when placed in this manner. If you need the overlay to span multiple faces, open the overlay's properties in SmartEdit mode, choose Brush Faces and then <Ctrl>-Click in the camera window to add more faces.

The overlay is a more powerful version of a standard decal: it can be resized, rotated, scaled, and distorted. Overlays can also be placed on displacements, where decals can't.

Template:Intent

There can be a max amount of 512 overlays in a single map file. The info_overlays are all packed into a special lump in the BSP file. To enable accesses by name, a func_overlay_accessor entity is created in the compiled map, which translates targetnames to info_overlay ID numbers.

Distorting overlays

If the overlay is not yet placed, select the overlay tool and your material, and click where you wish the center of the overlay to be. You should now see 4 white boxes at the edges of the overlay, and you may drag them about to distort it.

If you wish to distort an existing overlay, first select the overlay you wish to edit, and then select the overlay tool. Then you should be able to distort the overlay as described above. If the overlay does not respond, try deleting it and then following the above procedure.

Keyvalues

Name ([todo internal name (i)]) <targetname>
Name of the overlay. Used to access the overlay with an env_texturetoggle.
Material ([todo internal name (i)]) <material>
The material to overlay.
Brush faces ([todo internal name (i)]) <sidelist>
Faces on which the overlay will be applied.
RenderOrder ([todo internal name (i)]) <integer>
Higher values render after lower values (on top). This value can be 0–3.
U Start, U End, V Start, V End ([todo internal name (i)]) <float>
Texture coordinates
Overlay Basis Origin (Read-Only) ([todo internal name (i)]) <vector>
Overlay Basis U (Read-Only) ([todo internal name (i)]) <vector>
Overlay Basis V (Read-Only) ([todo internal name (i)]) <vector>
Overlay Basis Normal (Read-Only) ([todo internal name (i)]) <vector>
Start Fade Dist ([todo internal name (i)]) <float>
End Fade Dist ([todo internal name (i)]) <float>