2D Toolkit Forum
2D Toolkit => Support => Topic started by: csotomon on December 05, 2012, 02:26:12 am
-
How can I make that my sprite become afected by the unity fog and a spot Light?
-
You can use one of the lit shaders. Also be sure to change this http://unikronsoftware.com/2dtoolkit/doc/reference/sprite_collection.html Normal Generation -> Normals only.
-
Hi, with this changes, the sprite is affected by the spot light, but no for the fog, how can i solve this?
-
You'll have to change the shaders, or copy them and then modify the copy, whichever you prefer. The shaders have fog turned off explicitly to save performance - in a vast majority of cases there isn't much use to fogging sprites.
In the shader, you will find a line like this:
Fog { Mode Off }
You will need to switch it to something more appropriate based on this:
http://docs.unity3d.com/Documentation/Components/SL-Fog.html
-
Thank you for U help
-
Have someone used the "2D Volumetric Lighting system" available on the asset store? http://reverieinteractive.com/2dvls
I am thinking to give it a try