Material map compile flags: Difference between revisions
SirYodaJedi (talk | contribs) m (→Other: use deprecated template for origin brushes) |
SirYodaJedi (talk | contribs) m (Links) |
||
Line 24: | Line 24: | ||
! Effect | ! Effect | ||
|- id="%CompileClip" | |- id="%CompileClip" | ||
| %CompileClip | | [[%CompileClip]] | ||
| toolsclip | | toolsclip | ||
| | | | ||
| Makes the brush block only [[player]]s and [[NPC]]s. This is equivalent to a combination of <tt>%PlayerClip</tt> and <tt>%CompileNPCClip</tt>. | | Makes the brush block only [[player]]s and [[NPC]]s. This is equivalent to a combination of <tt>%PlayerClip</tt> and <tt>%CompileNPCClip</tt>. | ||
|- id="%CompileNPCClip" | |- id="%CompileNPCClip" | ||
| %CompileNPCClip | | [[%CompileNPCClip]] | ||
| toolsnpcclip | | toolsnpcclip | ||
| | | | ||
| Makes the brush block only [[NPC]]s. This implies <tt>NoLight</tt> and </tt>NoDraw</tt>.<br>{{ModernNote|{{csgo}} Blocks [[bot]]s, even though they are [[player]]s.}} | | Makes the brush block only [[NPC]]s. This implies <tt>NoLight</tt> and </tt>NoDraw</tt>.<br>{{ModernNote|{{csgo}} Blocks [[bot]]s, even though they are [[player]]s.}} | ||
|- id="%PlayerClip" | |- id="%PlayerClip" | ||
| %PlayerClip | | [[%PlayerClip]] | ||
| toolsplayerclip | | toolsplayerclip | ||
| | | | ||
| Makes the brush only block [[player]]s. | | Makes the brush only block [[player]]s. | ||
|- id="%compileplayercontrolclip" | |- id="%compileplayercontrolclip" | ||
| %CompilePlayerControlClip | | [[%CompilePlayerControlClip]] | ||
| toolscontrolclip | | toolscontrolclip | ||
| {{hl2ep2|removed}}{{Gmod|also}} | | {{hl2ep2|removed}}{{Gmod|also}} | ||
| Unsure as to how this was meant to be used. Usually seen together with {{ent|func_vehicleclip}}.<br>Material also uses <code>[[$surfaceprop]] player_control_clip<code>. | | Unsure as to how this was meant to be used. Usually seen together with {{ent|func_vehicleclip}}.<br>Material also uses <code>[[$surfaceprop]] player_control_clip<code>. | ||
|- id="%CompileGrenadeClip" | |- id="%CompileGrenadeClip" | ||
| %CompileGrenadeClip | | [[%CompileGrenadeClip]] | ||
| toolsgrenadeclip | | toolsgrenadeclip | ||
| {{csgo|only}} | | {{csgo|only}} | ||
| Makes the brush only block grenades. | | Makes the brush only block grenades. | ||
|- id="%CompileDroneClip" | |- id="%CompileDroneClip" | ||
| %CompileDroneClip | | [[%CompileDroneClip]] | ||
| toolsdroneclip | | toolsdroneclip | ||
| {{csgo|only}} | | {{csgo|only}} | ||
Line 62: | Line 62: | ||
! Effect | ! Effect | ||
|- id="%Compile2DSky" | |- id="%Compile2DSky" | ||
| %Compile2DSky | | [[%Compile2DSky]] | ||
| toolsskybox2d | | toolsskybox2d | ||
| | | | ||
| Makes the face render the 2D [[Skybox]] only, in addition to emitting <tt>light_environment</tt> light. | | Makes the face render the 2D [[Skybox]] only, in addition to emitting <tt>light_environment</tt> light. | ||
|- id="%CompileFog" | |- id="%CompileFog" | ||
| %CompileFog | | [[%CompileFog]] | ||
| ToolsFog | | ToolsFog | ||
| | | | ||
| This may be a deprecated flag that so far has not been seen as being useful. | | This may be a deprecated flag that so far has not been seen as being useful. | ||
|- id="%CompileNoChop" | |- id="%CompileNoChop"]] | ||
| %CompileNoChop | | [[%CompileNoChop]] | ||
| | | | ||
| | | | ||
| Prevents "subdividing patches" on the surface. This presumably affects how the face is converted to triangles. | | Prevents "subdividing patches" on the surface. This presumably affects how the face is converted to triangles. | ||
|- id="%CompileNoLight" | |- id="%CompileNoLight" | ||
| %CompileNoLight | | [[%CompileNoLight]] | ||
| nolight | | nolight | ||
| {{as|since}}{{src13|also}} | | {{as|since}}{{src13|also}} | ||
| Disables generating lightmaps for a brush face. Useful for materials that don't need lighting info or are always invisible. This is disabled on water materials. | | Disables generating lightmaps for a brush face. Useful for materials that don't need lighting info or are always invisible. This is disabled on water materials. | ||
|- id="%CompileOrigin" | |- id="%CompileOrigin" | ||
| %CompileOrigin | | [[%CompileOrigin]] | ||
| toolsorigin | | toolsorigin | ||
| | | | ||
| {{modernDeprecated|Sets the rotation origin of a brush entity.<br>Leftover from {{code|preset=0|[[Tool textures (GoldSrc)|ORIGIN]]}} in {{GoldSrc}}. Still functional in some branches (such as {{src13sp}}), but is no longer necessary.}} | | {{modernDeprecated|Sets the rotation origin of a brush entity.<br>Leftover from {{code|preset=0|[[Tool textures (GoldSrc)|ORIGIN]]}} in {{GoldSrc}}. Still functional in some branches (such as {{src13sp}}), but is no longer necessary.}} | ||
|- id="%CompileSkip" | |- id="%CompileSkip" | ||
| %CompileSkip | | [[%CompileSkip]] | ||
| toolsskip | | toolsskip | ||
| | | | ||
| Removes the face during compilation, making the brush into sets of planes. | | Removes the face during compilation, making the brush into sets of planes. | ||
|- id="%CompileSky" | |- id="%CompileSky" | ||
| %CompileSky | | [[%CompileSky]] | ||
| toolsskybox | | toolsskybox | ||
| | | | ||
| Makes the face render the (2D/3D) [[Skybox]] and emit {{ent|light_environment}} light. | | Makes the face render the (2D/3D) [[Skybox]] and emit {{ent|light_environment}} light. | ||
|- id="%CompileTrigger" | |- id="%CompileTrigger" | ||
| %CompileTrigger | | [[%CompileTrigger]] | ||
| toolstrigger | | toolstrigger | ||
| | | | ||
Line 112: | Line 112: | ||
! Effect | ! Effect | ||
|- id="%CompileBlockLOS" | |- id="%CompileBlockLOS" | ||
| %CompileBlockLOS | | [[%CompileBlockLOS]] | ||
| toolsblocklos | | toolsblocklos | ||
| | | | ||
| Makes the brush block only the [[line of sight]] for [[NPC]]s.<br>{{ModernNote|Also works for [[bot]]s in {{csgo}}.}} | | Makes the brush block only the [[line of sight]] for [[NPC]]s.<br>{{ModernNote|Also works for [[bot]]s in {{csgo}}.}} | ||
|- id="%CompileDetail" | |- id="%CompileDetail" | ||
| %CompileDetail | | [[%CompileDetail]] | ||
| | | | ||
| | | | ||
| Forces the brush to no longer cut [[visleaf]]s, similar to {{ent|func_detail}}. | | Forces the brush to no longer cut [[visleaf]]s, similar to {{ent|func_detail}}. | ||
|- id="%CompileHint" | |- id="%CompileHint" | ||
| %CompileHint | | [[%CompileHint]] | ||
| toolshint | | toolshint | ||
| | | | ||
| Makes the face hint-cut [[visleaf]]s. This implies <tt>NoLight</tt> and <tt>NoDraw</tt>. | | Makes the face hint-cut [[visleaf]]s. This implies <tt>NoLight</tt> and <tt>NoDraw</tt>. | ||
|- id="%CompileInvisible" | |- id="%CompileInvisible" | ||
| %CompileInvisible | | [[%CompileInvisible]] | ||
| toolsinvisible | | toolsinvisible | ||
| | | | ||
Line 137: | Line 137: | ||
| Makes the brush usable as a {{ent|func_ladder}}.<br>Can be applied to any material, such as <code>metal/metalladder.vmt</code> for a cheap ladder without a prop. Else also add %compilenodraw to make it invisible. | | Makes the brush usable as a {{ent|func_ladder}}.<br>Can be applied to any material, such as <code>metal/metalladder.vmt</code> for a cheap ladder without a prop. Else also add %compilenodraw to make it invisible. | ||
|- id="%CompileNoDraw" | |- id="%CompileNoDraw" | ||
| %CompileNoDraw | | [[%CompileNoDraw]] | ||
| toolsnodraw | | toolsnodraw | ||
| | | | ||
| Makes a brush behave like <code>tools/toolsnodraw</code>. | | Makes a brush behave like <code>tools/toolsnodraw</code>. | ||
|- id="%CompileNonSolid" | |- id="%CompileNonSolid" | ||
| %CompileNonSolid | | [[%CompileNonSolid]] | ||
| | | | ||
| | | | ||
| Makes the brush not solid to anything. <br>{{ModernBug|{{l4d2}} Turns brushes non-solid '''and invisible''' but still casts shadows.}} | | Makes the brush not solid to anything. <br>{{ModernBug|{{l4d2}} Turns brushes non-solid '''and invisible''' but still casts shadows.}} | ||
|- id="%CompileNoShadows" | |- id="%CompileNoShadows" | ||
| %CompileNoShadows | | [[%CompileNoShadows]] | ||
| | | | ||
| | | | ||
Line 153: | Line 153: | ||
{{ModernBug|Non-functional in {{tf2}}.}} | {{ModernBug|Non-functional in {{tf2}}.}} | ||
|- id="%CompilePassBullets" | |- id="%CompilePassBullets" | ||
| %CompilePassBullets | | [[%CompilePassBullets]] | ||
| | | | ||
| | | | ||
Line 164: | Line 164: | ||
| Decides which team should be affected by this tool texture. | | Decides which team should be affected by this tool texture. | ||
|- id="%CompileWater" | |- id="%CompileWater" | ||
| %CompileWater | | [[%CompileWater]] | ||
| | | | ||
| | | | ||
| Marks the brush as a [[Water (shader)|water]]-type material. Makes it non-solid, allows swimming inside, etc. If <code>%CompileKeepLight</code> is also set, the brush will retain its lighting data. | | Marks the brush as a [[Water (shader)|water]]-type material. Makes it non-solid, allows swimming inside, etc. If <code>%CompileKeepLight</code> is also set, the brush will retain its lighting data. | ||
|- id="%CompileSlime" | |- id="%CompileSlime" | ||
| %CompileSlime | | [[%CompileSlime]] | ||
| | | | ||
| | | | ||
| same as %CompileWater, but with green splash particles. <br>{{ModernBug|{{l4d2}} <tt>%CompileSlime</tt> uses default water splash particles.}} | | same as %CompileWater, but with green splash particles. <br>{{ModernBug|{{l4d2}} <tt>%CompileSlime</tt> uses default water splash particles.}} | ||
|- id="%NoPortal" | |- id="%NoPortal" | ||
| %NoPortal | | [[%NoPortal]] | ||
| toolsblack_noportal | | toolsblack_noportal | ||
| {{Portalseries|only}} | | {{Portalseries|only}} | ||
| Makes the texture non-portalable unless [[Gel (Portal 2)|Conversion Gel]] is used. | | Makes the texture non-portalable unless [[Gel (Portal 2)|Conversion Gel]] is used. | ||
|- id="%NoPaint" | |- id="%NoPaint" | ||
| %NoPaint | | [[%NoPaint]] | ||
| | | | ||
| {{portal2|only}} | | {{portal2|only}} | ||
| Makes the material unable to be painted by [[Gel (Portal 2)|Gel]]. | | Makes the material unable to be painted by [[Gel (Portal 2)|Gel]]. | ||
|- id="%CompileStairs" | |- id="%CompileStairs" | ||
| %CompileStairs | | [[%CompileStairs]] | ||
| toolsstairs | | toolsstairs | ||
| {{infra|only}} | | {{infra|only}} |
Revision as of 13:49, 22 May 2023
Several special shader parameters exist that start with a %
sign instead of $. These are read by the compile tools to alter the properties of the face or the brush they are attached to. Most are intended to produce the special tools/
textures, but they may also be used for other materials.
All flags are boolean properties and invisible to players. So far %CompileLadder is the only flag which may be visible to players, depending on the proxies inside the material. %CompileTeam Is also the only flag that is not a boolean.
See also Tool Textures for more detail about the propeties of individual materials.

LightmappedGeneric { $basetexture developer/custom_clip %compileclip 1 }
Exclusive Flags
Only one of the following flags may be set on any given material.
Every flag is available in all Source Engine branches, unless specifically mentioned in the Availability
box
Clips
Name | Seen in .vmt | Availability | Effect |
---|---|---|---|
%CompileClip | toolsclip | Makes the brush block only players and NPCs. This is equivalent to a combination of %PlayerClip and %CompileNPCClip. | |
%CompileNPCClip | toolsnpcclip | Makes the brush block only NPCs. This implies NoLight and NoDraw. Template:ModernNote | |
%PlayerClip | toolsplayerclip | Makes the brush only block players. | |
%CompilePlayerControlClip | toolscontrolclip | (removed since ![]() ![]() |
Unsure as to how this was meant to be used. Usually seen together with func_vehicleclip. Material also uses $surfaceprop player_control_clip |
%CompileGrenadeClip | toolsgrenadeclip | (only in ![]() |
Makes the brush only block grenades. |
%CompileDroneClip | toolsdroneclip | (only in ![]() |
Makes the brush only block drones. |
Other
Name | Seen in .vmt | Availability | Effect |
---|---|---|---|
%Compile2DSky | toolsskybox2d | Makes the face render the 2D Skybox only, in addition to emitting light_environment light. | |
%CompileFog | ToolsFog | This may be a deprecated flag that so far has not been seen as being useful. | |
%CompileNoChop | Prevents "subdividing patches" on the surface. This presumably affects how the face is converted to triangles. | ||
%CompileNoLight | nolight | (in all games since ![]() ![]() |
Disables generating lightmaps for a brush face. Useful for materials that don't need lighting info or are always invisible. This is disabled on water materials. |
%CompileOrigin | toolsorigin | ![]() Leftover from ORIGIN in ![]() ![]() | |
%CompileSkip | toolsskip | Removes the face during compilation, making the brush into sets of planes. | |
%CompileSky | toolsskybox | Makes the face render the (2D/3D) Skybox and emit light_environment light. | |
%CompileTrigger | toolstrigger | Makes the brush suitable for Triggers. |
Additive Flags
Multiple of the following flags may be applied to any given material.
Every flag is available in all Source Engine branches, unless specifically mentioned in the Availability
box
Name | Seen in .vmt | Availability | Effect |
---|---|---|---|
%CompileBlockLOS | toolsblocklos | Makes the brush block only the line of sight for NPCs. Template:ModernNote | |
%CompileDetail | Forces the brush to no longer cut visleafs, similar to func_detail. | ||
%CompileHint | toolshint | Makes the face hint-cut visleafs. This implies NoLight and NoDraw. | |
%CompileInvisible | toolsinvisible | Makes a surface behave like NoDraw, but still allows bullets to pass through it, except in ![]() | |
%CompileLadder | toolsladder | Makes the brush usable as a func_ladder. Can be applied to any material, such as metal/metalladder.vmt for a cheap ladder without a prop. Else also add %compilenodraw to make it invisible.
| |
%CompileNoDraw | toolsnodraw | Makes a brush behave like tools/toolsnodraw .
| |
%CompileNonSolid | Makes the brush not solid to anything. Template:ModernBug | ||
%CompileNoShadows | Prevents shadows from being cast onto the texture. | ||
%CompilePassBullets | Makes the brush behave like a grating, allowing bullets to pass through but blocking other objects. Useful for foliage or metal grates. Template:ModernNote | ||
%CompileTeam | climb_versus | (only in ![]() ![]() |
Decides which team should be affected by this tool texture. |
%CompileWater | Marks the brush as a water-type material. Makes it non-solid, allows swimming inside, etc. If %CompileKeepLight is also set, the brush will retain its lighting data.
| ||
%CompileSlime | same as %CompileWater, but with green splash particles. Template:ModernBug | ||
%NoPortal | toolsblack_noportal | (only in ![]() |
Makes the texture non-portalable unless Conversion Gel is used. |
%NoPaint | (only in ![]() |
Makes the material unable to be painted by Gel. | |
%CompileStairs | toolsstairs | (only in ![]() |
Makes brushwork traversable up to an angle of 63.4349488, as opposed to the usual 45°. |