I have four different skyboxes, one for each season in my game.
How can I create a fade transition between the skyboxes in c#?
So for example, at a certain point, the summer skybox fades into the autumn skybox.
Thank you!
You'll want to do the blending in a shader, there's one on the Unify wiki that can blend between two skyboxes.
You need to swap the textures in your material using a script (using material.SetTexture) when it's finished blending between 2 of them to get the effect of blending between 4.
material.SetFloat("_Blend" , Mathf.Lerp(material.GetFloat("_Blend"),1,Time.deltaTime)); but that gives you fast blending at the start, and slows down to a stop just before reaching 1. The best way to do it is laid out well in this article:chicounity3d.wordpress.com/2014/05/23/how-to-lerp-like-a-pro