• Unity
  • Problem on rotating heads when exported to Unity

Hey guys,

I have a problem with my spine animation when exported to Unity. When viewed in the editor, everything seems fine, but when it is exported to Unity, the heads suddenly rotates counter clockwise.

I tried checking any possible problem, like removing bones, removed mesh of the head and tried using other head but it doesn't seem to work. Here you can see that we tried head swap, the left one is ok, but the right is not.

Could you please help me with this? I'll greatly appreciate any help I could get.

Thanks!
Gilbert

Related Discussions
...

when you say "suddenly" does it mean it happens in the middle of an animation? maybe you inadvertently added a key on the head rotation, if it happens in only one animation, I'd delete the head keys and redo that part just to make sure.
If it happens in any animation and even setup, then it's something else, but it seems to be skeleton-related. Could you check it?

Thanks for your reply Erikari. Btw, what I mean is that it happens everytime when run in Unity. Actually, I've already redone the bone for the head but to no avail.

Are you sure you don't have code or any extra misplaced components modifying the bone rotation?

Hey Pharan, I'm not sure if this is the problem. The rotation is not set to zero?

I compared it with the other animation that is working, and its rotation is set to zero.

Also the working one is using cross-hair type of bones and not the long one, if that has something to do with it.

Where is the screenshot where the head is in the correct position in the editor?
Can you confirm that the rotation rotation value in Unity is actually not what it is Spine? Can you send us this problematic assets? You can send to unity@esotericsoftware.com

By the way, if you're curious, if you right-click on the SkeletonAnimation component in Unity, you can open Spine-Unity's Skeleton Debug window. There you can select a specific bone and see its local and world values. It also has a bunch of other handy skeleton visualization tools like for paths and constraints.

Keep in mind you have World axes checked in the editor in the last screenshot. The screenshot before that doesn't show what axes are selected.