• Unity
  • Normal maps on separate moving parts

Hello.
I am trying to add a rim light effect in Unity to my character made in Spine. I use Spine/Sprite/Pixel Lit shader and a normal map to simulate this effect. It works fine until my character starts moving. It seems that lighting is calculated based on position of whole skeleton relative to the light source and ignores transformations of individual parts. That's why when character moves without changing his position it appears like the lights are 'baked' into the sprites while I am trying to achieve a dynamic change of how lighting affects the character.
Is it possible to achieve in current version? And if not are you planning to implement that in future?

Related Discussions
...

Hello.
Use of the lit sprite shaders with normal maps requires Tangents. Tangents can be generated by SkeletonAnimation by checking "Solve Tangents" under the "Advanced..." foldout in its inspector.'
Note that the bundled sprite shaders are capable of assuming a fixed normal, so there is no need for "Add Normals" to be checked under Advanced.

Thanks! It does seem to change how light affects individual parts.
But after I do that it seems to mess up how normal maps affect the character (parts get lit from wrong directions in idle animation while before they looked fine). It does not happen right after I enable that option but after I play any animation different from the idle one. My programmer generates the SkeletonAnimation in the runtime so I am enabling it while the game is running. What is the 'default state' of the parts when Solve Tangents is enabled?
Also do you have any documentation on that part? I couldn't find anything related to that.

Could you post a screenshot or anything do depict your current situation, before and after Solve tangents enabled?

Or even better, send us a zipped package of your exported files to contact@esotericsoftware.com, then we can better check what's going wrong here.

Regarding the top image before enabling Solve Tangents, to be sure: here the normal map is applied but Solve Tangents is disabled right?

What setting are you using at the material? Are you using Fixed Normals there? If yes, you could try changing the Fixed Normal Direction and Fixed Normal Space.

Enabling Fixed Normals helped.
I'll have to do some more work on the normal map to see if works 100% but for now it does seem to work fine.
Really thankful for the help.
P.S. Yea, sorry, I forgot to add an attachment to my mail. I guess there's no point doing that now.

Glad that fixed it, thanks for letting us know.