Lighting support error but work perfect when remove normal
-
- make any simple sprite shader with texture and master node and lighting support.
- its error.
3.remove this line and it work perfect
"o.Normal = UnpackNormal(float4(1,1,0,1));"
in function:
void surf(Input i, inout SurfaceOutput o)
{
float4 _MainTex_1 = tex2D(_MainTex, i.uv_MainTex);
float4 ColorRGBA_1 = ColorRGBA(_MainTex_1,_ColorRGBA_Color_1);
_MainTex_1 = lerp(_MainTex_1,ColorRGBA_1,_Lerp_Fade_1);
float4 FinalResult = _MainTex_1;
o.Albedo = FinalResult.rgb* i.color.rgb;
o.Alpha = FinalResult.a * _SpriteFade * i.color.a;
o.Normal = UnpackNormal(float4(1,1,0,1));
clip(o.Alpha - 0.05);
}