I wish to give a snow material on everything above a property “SnowLimit”, and moss material on everything below it.
This is my current approach, a simple if statement:
- Is the input in the form of Material Attributes, if the world Z is above SnowLimit, it’s snow, if it’s below it’s Moss.
This if statement approach results in no errors, but the material simply becomes “unrendered” (?), as if the if statement doesn’t return anything:
This is what it looks like plugging the snow material directly into “NotCliff” at 4:
I tried using a HeightLerp, as seen on 5, but this requires a texture or vec3 as input, so it doesn’t work “off the bat”. I could reorganize a bit to make the HeightLerp work but I prefer not to since I only need the simple if logic as I’ve implemented.
Why doesn’t it work? Am I thinking too “programatically” about how materials/shaders work?