- Home /
Tree Creator Shader will not fade
How can I have a tree made with Tree Creator (with Tree Creator Shaders) slowly fade over the course of a scene? I am not sure how to change the rendering setting of the tree so that changes in its alpha value will make it transparent.
I am calling the following code in update:
GameObject tree= GameObject.FindGameObjectWithTag("largeTree");
Color color = tree.GetComponent<Renderer>().material.color;
color.a -= 0.1f;
tree.GetComponent<Renderer>().material.SetColor ("_Color", color);
My tree currently has "Nature/Tree Creator Bark" and "Nature/Tree Creator Leaves" Shaders. I tried making the Tree Shader Standard and changing its render setting to Transparent, but this resulted in errors and still would not allow the tree's transparency to be changed.
Your answer
Follow this Question
Related Questions
Implement texture masking into simple existing shader 1 Answer
Using custom tree shaders? 1 Answer
How to prevent shader overlap in LWRP Shadergraph. 0 Answers
See backside of a transparent emissive shader? 0 Answers
RenderTexture lacks quality , Trees have a grey outline against the night sky 0 Answers