Hello Guest

Author Topic: Lighting does not affect sprites  (Read 4746 times)

w4dg

  • Newbie
  • *
  • Posts: 3
    • View Profile
Lighting does not affect sprites
« on: April 02, 2013, 03:13:31 am »
I was able to find a few other support threads with similar issues, but their solutions didn't seem to help me. I have:

  • Set my normal generation to "Normals Only"
  • Set my material shader to "LitBlendVertexColor" with Premultiplied Alpha set to off.
  • Set my material shader to "LitPremulVertexColor" with Premultiplied Alpha set to on.

In both cases, the sprite is simply invisible. Nonlit shaders appear to work just fine. The sprite in question is attached to the player controller. I love the organization of this add-on, by the way. You've done a great job.
« Last Edit: April 02, 2013, 03:20:52 am by w4dg »

unikronsoftware

  • Administrator
  • Hero Member
  • *****
  • Posts: 9709
    • View Profile
Re: Lighting does not affect sprites
« Reply #1 on: April 02, 2013, 12:08:47 pm »
This should just work after setting normal generation to true + shader to litblendvertexcolor.
Have you tried any of the default Unity shaders? What happens there?

w4dg

  • Newbie
  • *
  • Posts: 3
    • View Profile
Re: Lighting does not affect sprites
« Reply #2 on: April 02, 2013, 06:15:50 pm »
All of the default shaders result in either a black rectangle covering the entire area of the sprite, or something completely invisible.

= /

w4dg

  • Newbie
  • *
  • Posts: 3
    • View Profile
Re: Lighting does not affect sprites
« Reply #3 on: April 02, 2013, 06:19:56 pm »
Wow! I just hit "Reset Shaders" and reselected my texture and now it's working!

For anyone else having this problem, Reset Shaders is in the options (the little gear) to the upper right of your material atlas.

unikronsoftware

  • Administrator
  • Hero Member
  • *****
  • Posts: 9709
    • View Profile
Re: Lighting does not affect sprites
« Reply #4 on: April 03, 2013, 03:21:34 pm »
How bizzare.
Never seen this issue before. Perhaps the material was set up incorrectly intially.

Thanks for sharing.