$moss enable: Difference between revisions
mNo edit summary |
MyGamepedia (talk | contribs) |
||
Line 74: | Line 74: | ||
}} | }} | ||
}} | }} | ||
{{MatParam|$moss_scale|float|Scale for moss. Deprecated and non-functional. Use [[$seamless_scale]] instead, | {{MatParam|$moss_scale|float|Scale for moss. Deprecated and non-functional. Use [[$seamless_scale]] instead.}} | ||
{{MatParam|$moss_scale_turn_on_absolute|bool|Toggle moss scale between enabled and disabled state. 1 - enabled, 0 - disabled. Affects nothing at least in {{bms|4|nt=2}}.|deprecated=1}} | |||
{{MatParam|$seamless_scale|float|This parameter scales texture for this shader. | |||
{{expand|title=Examples.| | {{expand|title=Examples.| | ||
<gallery mode=packed heights=310px> | <gallery mode=packed heights=310px> | ||
File:20240602164627_1.jpg|<code>$seamless_scale 0</code> | File:20240602164627_1.jpg|<code>$seamless_scale 0</code> | ||
Line 82: | Line 83: | ||
</gallery> | </gallery> | ||
}} | }} | ||
}} | |||
==Bugs/Limitations== | ==Bugs/Limitations== |
Revision as of 11:02, 8 January 2025


$moss_enable
is a material shader parameter available in Black Mesa.

$moss_texture
used models/props_xen/moss_test/bubblemoss
.This is procedural moss implementation, which is triplanar projection shader that allows you to project additional texture that mixes with normalmap. This shader available for VertexLitGeneric, LightmappedGeneric and Lightmapped_4WayBlend shaders. It was created during development of Xen for Black Mesa and was designed to simulate presence of moss on surface.
For VertexLitGeneric, it uses the specified texture. For LightmappedGeneric and Lightmapped_4WayBlend, instead of using the texture itself for moss, this shader takes color that most of the texture consists of and then applies color to the surface according to the parameters specified in .vmt
.
All parameters works in the same way for both shaders.
In Black Mesa it was used for
models\props_xen\moss_test\sphereofchon.mdl
and models\props_xen\moss_test\test_moss001.mdl
models. Both using the models/props_xen/moss_test/bubblemoss
texture. The final version of the game doesn't use this shader in any of the maps. May be incompatible with some shaders (as it was with $phong).


Parameters and Effects
$moss_enable
$moss_texture
$moss_ref_direction
$moss_angle_theta
$moss_angle_phi
$moss_angle_falloff
$moss_blend_factor
$moss_scale
$moss_scale_turn_on_absolute
$seamless_scale
Bugs/Limitations
Incompatible with new specular shader
New specular shader doesn't blend with moss shader.
An example with LightmappedGeneric. The specular should be yellow instead of white.
An example with VertexLitGeneric. The specular should be green instead of white.
See also
- New Specular
- BlackMesa XenEngine: Part1 – Heavily Modified Source Engine (page from Black Mesa developer about Black Mesa engine, better known as XenEngine)