How to suppress "The tree must use Nature/Soft Occlusion shader" warning.

Hello! I’ve been using custom tree shaders for a while now, in various projects.
They work fine, but I always get this warning in my console.

The tree Bush must use the Nature/Soft Occlusion shader. Otherwise billboarding/lighting will not work correctly.

I’ve been doing some cleanup and I thought - it’s time to try and figure out how to get rid of this warning!
What can I do to my shader to make Unity realize it is a compatible tree shader?

EDIT: Nevermind, spoke too soon. This doesn’t work.

For anyone else that finds this post:

Tags
{
    "TerrainCompatible" = "True"
}

I’m finding this late, but having the same problem. To which script do I add your code snippet with the tag?

It’s unclear from the warning message but you can remove this warning by adding LODs to the object in question, in the OPs case add an LOD group to the ‘Bush’ object. If you wish to have a fast way of doing this consider using ‘AutoLOD’, its developed by Unity and works pretty well. Link to the repo is here, and you can import it through the package manager with the github link:

https://github.com/Unity-Technologies/AutoLOD

1 Like