$treesway: Difference between revisions
mNo edit summary |
ShiroDkxtro2 (talk | contribs) m (Consistency with $detail - $treesway does not work with $detailtexturetransform) |
||
Line 7: | Line 7: | ||
{{warning|Due to the way bumped lighting is calculated, <code>$treesway</code> will not sway materials which use {{ent|$bumpmap}}.}} | {{warning|Due to the way bumped lighting is calculated, <code>$treesway</code> will not sway materials which use {{ent|$bumpmap}}.}} | ||
{{note|This shader parameter is disabled by default in the {{as}} SDK. It can re-enabled by modding.}} | {{note|This shader parameter is disabled by default in the {{as}} SDK. It can re-enabled by modding.}} | ||
{{bug|This shader parameter does not work with [[$detail#Parameters and Effects|$detailtexturetransform]].}} | |||
{{bug|In {{GMOD}}{{mapbase}}, using a shadow-casting [[env_projectedtexture|projected texture]] on materials with this parameter will cause flickering. As a workaround, try to keep trees away from where player flashlights can reach. {{ent|$halflambert}} may also partially fix the issue.}} | {{bug|In {{GMOD}}{{mapbase}}, using a shadow-casting [[env_projectedtexture|projected texture]] on materials with this parameter will cause flickering. As a workaround, try to keep trees away from where player flashlights can reach. {{ent|$halflambert}} may also partially fix the issue.}} | ||
{{bug|In {{mapbase}}, using a shadow-casting [[env_projectedtexture|projected texture]] will cause shadows not reacting to <code>$treesway</code>, shadows don't move, expect in {{gmod}}.}} | {{bug|In {{mapbase}}, using a shadow-casting [[env_projectedtexture|projected texture]] will cause shadows not reacting to <code>$treesway</code>, shadows don't move, expect in {{gmod}}.}} |
Revision as of 11:59, 16 February 2023
Template:Shaderparam It is also available in . In
, it can also be used for UnlitGeneric.
$treesway
morphs a material around using the parameters of an env_wind entity to give the appearance of tree leaves and foilage blowing in the wind. The subparameters of $treesway
determine how much the env_wind
entity should affect the morphing, and all of them (except $treeswaystatic
) must be specified in order for the effect to work properly. This shader parameter assumes any model using it is facing upwards.

$treesway
will not sway materials which use $bumpmap.





$treesway
, shadows don't move, expect in 
- Todo: What about
$singlepassflashlight
and$flashlightnolambert
?
Parameters
$treesway
$treeswayheight
$treeswaystartheight
$treeswayradius
$treeswaystartradius
$treeswayspeed
$treeswaystrength
$treeswayscrumblespeed
$treeswayscrumblestrength
$treeswayscrumblefrequency
$treeswayfalloffexp
$treeswayscrumblefalloffexp
$treeswayspeedhighwindmultipler
$treeswayspeedlerpstart
$treeswayspeedlerpend
$treeswaystatic
$treeswaystaticvalues
See Also
https://gamebanana.com/tuts/12924 - How to achieve a similar effect without $treeSway
, on all source engine games