CompileTrigger: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
No edit summary
mNo edit summary
Line 1: Line 1:
Compiles the texture to be used for a [[Trigger]]
Compiles the texture to be used for a [[Trigger]]


Generally "Tools/toolstrigger" could be used for any trigger. But if a mod/map has multiple types of triggers, one could make multiple tool textures to differentiate the types of triggers easier. Such as [[trigger_hurt]], [[trigger_once]], [[trigger_multiple]]...<br>
Generally "Tools/toolstrigger" could be used for any trigger, but if a mod/map has multiple types of brush entities that use Tools/toolstrigger, one could make multiple tool textures to differentiate the types of entities easier, such as {{ent|trigger_hurt}}, {{ent|trigger_once}}, {{ent|trigger_multiple}}, {{ent|parallax_obb}}, etc.<br>
{{note|Different textures will have no functional effect, unless paired with other [[Shader Parameters]].}}
{{note|Different textures will have no functional effect, unless paired with other [[Shader Parameters]].}}
==Example==
==Example==
LightmappedGeneric
Example uses {{shader Name|LightmappedGeneric}}, however {{shader Name|UnlitGeneric}} also works as well.
{{pre|LightmappedGeneric
  {
  {
  $translucent 1
  $translucent 1
Line 12: Line 13:
  "%keywords" "airexchange,borealis,c17downtown,c17industrial,c17sewers,c17skyscraper,c17trainstation,combine,kraken,wasteland"
  "%keywords" "airexchange,borealis,c17downtown,c17industrial,c17sewers,c17skyscraper,c17trainstation,combine,kraken,wasteland"
  }
  }
 
}}
[[Category:Material System]]
[[Category:Material System]]
[[Category:Shader parameters]]
[[Category:Shader parameters]]

Revision as of 08:11, 22 August 2023

Compiles the texture to be used for a Trigger

Generally "Tools/toolstrigger" could be used for any trigger, but if a mod/map has multiple types of brush entities that use Tools/toolstrigger, one could make multiple tool textures to differentiate the types of entities easier, such as trigger_hurt, trigger_once, trigger_multiple, parallax_obb, etc.

Note.pngNote:Different textures will have no functional effect, unless paired with other Shader Parameters.

Example

Example uses Shader-ball.png LightmappedGeneric, however Shader-ball.png UnlitGeneric also works as well.

LightmappedGeneric
 {
 	$translucent 1
 	$basetexture "Tools/toolstrigger"
 	"srgb?$basetexture" "Tools/toolstrigger-dx10"
 	"%compiletrigger" 1
 	"%keywords" "airexchange,borealis,c17downtown,c17industrial,c17sewers,c17skyscraper,c17trainstation,combine,kraken,wasteland"
 }