Template:VT/doc: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
m (THE OWL moved page Template:KV Type/doc to Template:VT/doc)
Line 10: Line 10:
! Code !! Output !! Other Values !! Notes
! Code !! Output !! Other Values !! Notes
|-
|-
| <code><nowiki>{{KV Type|axis}}</nowiki></code> || {{KV Type|axis}} || ||
| <code><nowiki>{{VT|axis}}</nowiki></code> || {{VT|axis}} || ||
|-
|-
| <code><nowiki>{{KV Type|bool}}</nowiki></code> || {{KV Type|bool}} || boolean || {{asbranch|since}} {{gmod|also}} <br>Use <tt>choices</tt> instead in earlier games.
| <code><nowiki>{{VT|bool}}</nowiki></code> || {{VT|bool}} || boolean || {{asbranch|since}} {{gmod|also}} <br>Use <tt>choices</tt> instead in earlier games.
|-
|-
| <code><nowiki>{{KV Type|choices}}</nowiki></code> || {{KV Type|choices}} || ||
| <code><nowiki>{{VT|choices}}</nowiki></code> || {{VT|choices}} || ||
|-
|-
| <code><nowiki>{{KV Type|color255}}</nowiki></code> || {{KV Type|color255}} || RGB ||
| <code><nowiki>{{VT|color255}}</nowiki></code> || {{VT|color255}} || RGB ||
|-
|-
| <code><nowiki>{{KV Type|color255 + int}}</nowiki></code> || {{KV Type|color255 + int}} || color255+int ||
| <code><nowiki>{{VT|color255 + int}}</nowiki></code> || {{VT|color255 + int}} || color255+int ||
|-
|-
| style="width: 20%"| <code><nowiki>{{KV Type|env_cubemap / texture}}</nowiki></code> || {{KV Type|env_cubemap / texture}} || cubemap/texture, cubemap / texture, env cubemap/texture, env cubemap / texture, env_cubemap/texture ||
| style="width: 20%"| <code><nowiki>{{VT|env_cubemap / texture}}</nowiki></code> || {{VT|env_cubemap / texture}} || cubemap/texture, cubemap / texture, env cubemap/texture, env cubemap / texture, env_cubemap/texture ||
|-
|-
| <code><nowiki>{{KV Type|filter}}</nowiki></code> || {{KV Type|filter}} || filterclass ||
| <code><nowiki>{{VT|filter}}</nowiki></code> || {{VT|filter}} || filterclass ||
|-
|-
| <code><nowiki>{{KV Type|float}}</nowiki></code> || {{KV Type|float}} || ||
| <code><nowiki>{{VT|float}}</nowiki></code> || {{VT|float}} || ||
|-
|-
| <code><nowiki>{{KV Type|int}}</nowiki></code> || {{KV Type|int}} || integer ||
| <code><nowiki>{{VT|int}}</nowiki></code> || {{VT|int}} || integer ||
|-
|-
| <code><nowiki>{{KV Type|int 0-10}}</nowiki></code> || {{KV Type|int 0-10}} || || For {{ent|mode=link|ambient_generic}}
| <code><nowiki>{{VT|int 0-10}}</nowiki></code> || {{VT|int 0-10}} || || For {{ent|mode=link|ambient_generic}}
|-
|-
| <code><nowiki>{{KV Type|int 0-100}}</nowiki></code> || {{KV Type|int 0-100}} || || For {{ent|mode=link|ambient_generic}}
| <code><nowiki>{{VT|int 0-100}}</nowiki></code> || {{VT|int 0-100}} || || For {{ent|mode=link|ambient_generic}}
|-
|-
| <code><nowiki>{{KV Type|int 0-1000}}</nowiki></code> || {{KV Type|int 0-1000}} || || For {{ent|mode=link|ambient_generic}}
| <code><nowiki>{{VT|int 0-1000}}</nowiki></code> || {{VT|int 0-1000}} || || For {{ent|mode=link|ambient_generic}}
|-
|-
| <code><nowiki>{{KV Type|int 0-255}}</nowiki></code> || {{KV Type|int 0-255}} || || For {{ent|mode=link|ambient_generic}}
| <code><nowiki>{{VT|int 0-255}}</nowiki></code> || {{VT|int 0-255}} || || For {{ent|mode=link|ambient_generic}}
|-
|-
| <code><nowiki>{{KV Type|property}}</nowiki></code> || {{KV Type|property}} || material property || Is a link to [[Material surface properties]].
| <code><nowiki>{{VT|property}}</nowiki></code> || {{VT|property}} || material property || Is a link to [[Material surface properties]].
|-
|-
| <code><nowiki>{{KV Type|RGB matrix}}</nowiki></code> || {{KV Type|RGB matrix}} || || Is two separate links.
| <code><nowiki>{{VT|RGB matrix}}</nowiki></code> || {{VT|RGB matrix}} || || Is two separate links.
|-
|-
| <code><nowiki>{{KV Type|script}}</nowiki></code> || {{KV Type|script}} || vscript ||rowspan="2"| Is a link to [[Vscript]].
| <code><nowiki>{{VT|script}}</nowiki></code> || {{VT|script}} || vscript ||rowspan="2"| Is a link to [[Vscript]].
|-
|-
| <code><nowiki>{{KV Type|scriptlist}}</nowiki></code> || {{KV Type|scriptlist}} ||
| <code><nowiki>{{VT|scriptlist}}</nowiki></code> || {{VT|scriptlist}} ||
|-
|-
| <code><nowiki>{{KV Type|string}}</nowiki></code> || {{KV Type|string}} || str ||
| <code><nowiki>{{VT|string}}</nowiki></code> || {{VT|string}} || str ||
|-
|-
| <code><nowiki>{{KV Type|studio}}</nowiki></code> || {{KV Type|studio}} || model, modelname, model name, modelpath, model path || Is a link to [[Model]].
| <code><nowiki>{{VT|studio}}</nowiki></code> || {{VT|studio}} || model, modelname, model name, modelpath, model path || Is a link to [[Model]].
|-
|-
| <code><nowiki>{{KV Type|target}}</nowiki></code> || {{KV Type|target}} || target_name, target_destination, target_source ||
| <code><nowiki>{{VT|target}}</nowiki></code> || {{VT|target}} || target_name, target_destination, target_source ||
|-
|-
| <code><nowiki>{{KV Type|vector}}</nowiki></code> || {{KV Type|vector}} || vecline ||  
| <code><nowiki>{{VT|vector}}</nowiki></code> || {{VT|vector}} || vecline ||  
|-
|-
| <code><nowiki>{{KV Type|vector2}}</nowiki></code> || {{KV Type|vector2}} || ||  
| <code><nowiki>{{VT|vector2}}</nowiki></code> || {{VT|vector2}} || ||  
|-
|-
| <code><nowiki>{{KV Type|vector3}}</nowiki></code> || {{KV Type|vector3}} || ||  
| <code><nowiki>{{VT|vector3}}</nowiki></code> || {{VT|vector3}} || ||  
|-
|-
| <code><nowiki>{{KV Type|vector4}}</nowiki></code> || {{KV Type|vector4}} || ||  
| <code><nowiki>{{VT|vector4}}</nowiki></code> || {{VT|vector4}} || ||  
|-
|-
| <code><nowiki>{{KV Type|void}}</nowiki></code> || {{KV Type|void}} || <blank> ||
| <code><nowiki>{{VT|void}}</nowiki></code> || {{VT|void}} || <blank> ||
|}
|}
Any other input will be a link to that input.
Any other input will be a link to that input.
==See Also==
==See Also==
*{{tl|IO}}
*{{tl|IO}}

Revision as of 05:09, 18 March 2023

Edit-copy.png
This is a documentation subpage for Template:VT.
Don't forget to purge the contents of the base page upon creating or editing this subpage.

Just a list template for FGD and shader parameter templates to easily link to a wide variety of variable types.

Usage

This template accepts one parameter: the name of the variable type. It outputs a specific string depending on this parameter. It is not case-sensitive.

The following table lists inputs, their results, other inputs yielding the same results, and any things to note. Case variations are not included.

Code Output Other Values Notes
{{VT|axis}} <axis>
{{VT|bool}} <boolean> boolean (in all games since Alien Swarm engine branch) (also in Garry's Mod)
Use choices instead in earlier games.
{{VT|choices}} <choices>
{{VT|color255}} <color255> RGB
{{VT|color255 + int}} <color255 + int> color255+int
{{VT|env_cubemap / texture}} <env_cubemap/texture> cubemap/texture, cubemap / texture, env cubemap/texture, env cubemap / texture, env_cubemap/texture
{{VT|filter}} <filter> filterclass
{{VT|float}} <float>
{{VT|int}} <integer> integer
{{VT|int 0-10}} <integer 0–10> For ambient_generic
{{VT|int 0-100}} <integer 0–100> For ambient_generic
{{VT|int 0-1000}} <integer 0–1000> For ambient_generic
{{VT|int 0-255}} <integer 0–255> For ambient_generic
{{VT|property}} <property> material property Is a link to Material surface properties.
{{VT|RGB matrix}} <RGB matrix> Is two separate links.
{{VT|script}} <script> vscript Is a link to Vscript.
{{VT|scriptlist}} <scriptlist>
{{VT|string}} <string> str
{{VT|studio}} <model path> model, modelname, model name, modelpath, model path Is a link to Model.
{{VT|target}} <targetname> target_name, target_destination, target_source
{{VT|vector}} <vector> vecline
{{VT|vector2}} <vector2>
{{VT|vector3}} <vector3>
{{VT|vector4}} <vector4>
{{VT|void}} <void> <blank>

Any other input will be a link to that input.

See Also

  • {{IO}}
  • {{KV}}
  • {{MatParam}}