Env texturetoggle: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
No edit summary
(updates)
Line 1: Line 1:
[[File:env_texturetoggle.png|left|link=]]
{{lang|Env texturetoggle}}
[[File:env_texturetoggle.png|left|link=]]{{base point|env_texturetoggle}} It allows you to change the textures on brush entities or overlays.


{{base point|env_texturetoggle}} It allows you to change the textures on other brush-built entities.
In order for <code>env_texturetoggle</code> to work properly, your overlay or at least one face of your brush must use a [[VMT]] material with the <code>[[List Of Material Proxies#Texture manipulation|ToggleTexture</code> proxy]] defined and pointing to an animated [[VTF]] file with at least two frames.


In order for env_texturetoggle to work properly, your overlay or at least one face of your brush must use a [[VMT]] material with the [[List Of Material Proxies#Texture manipulation|''ToggleTexture'' proxy]] defined and pointing to an Animated [[VTF]] file with at least two frames.
{{code class|CTextureToggle|env_texturetoggle.cpp}}


Compare this with the [[material_modify_control]] entity that can modify any parameter of a material globally.
==Keyvalues==
{{clr}}
{{KV|Target Brush(es) (target)|target_destination|Name of the brushes or {{ent|info_overlay}}s. All <code>ToggleTexture</code> materials on all entities (including sprites) matching the targetname will be affected.}}
{{KV BaseEntity}}


== Keyvalues ==
==Inputs==
{{KV|Target Brush(es).|target_destination|Name of the brushes or [[info_overlay]]s. All ''ToggleTexture'' materials on all entities (including sprites) matching the targetname will be affected.}}
{{IO|IncrementTextureIndex|Increments target brush's current texture frame by one.}}
{{KV Targetname}}
{{IO|SetTextureIndex|param=integer|Sets target brush's texture frame to the specified index.}}
{{I BaseEntity}}


== Inputs ==
==Outputs==
{{IO|IncrementTextureIndex|Increments target brush's current texture frame by one.}}
{{O BaseEntity|l4d=1}}
{{IO|SetTextureIndex|Sets target brush's texture frame to the specified index.|param=integer}}
{{I Targetname}}


== Outputs ==
==See Also==
{{O Targetname}}
*{{ent|material_modify_control}}

Revision as of 21:13, 2 October 2018

English (en)中文 (zh)Translate (Translate)
Env texturetoggle.png

Template:Base point It allows you to change the textures on brush entities or overlays.

In order for env_texturetoggle to work properly, your overlay or at least one face of your brush must use a VMT material with the ToggleTexture proxy defined and pointing to an animated VTF file with at least two frames.

C++ In code, it is represented by theCTextureToggleclass, defined in theenv_texturetoggle.cppfile.

Keyvalues

Target Brush(es) (target) ([todo internal name (i)]) <targetname>
Name of the brushes or info_overlays. All ToggleTexture materials on all entities (including sprites) matching the targetname will be affected.


Inputs

IncrementTextureIndex
Increments target brush's current texture frame by one.
SetTextureIndex <integerRedirectInput/integer>
Sets target brush's texture frame to the specified index.


Outputs

See Also