• RuntimesUnity
  • Bones in "Spine" skins are not displayed in unity

Hello. Unity when mixing skins for some reason does not display the bones hidden in the skins.
I made an animation of cars, There are 5 skins of cars and 5 skins of characters.
In the skins of each car there is a bone to which the character is attracted when we turn on a certain machine. But in unity, for some reason, the bones stuffed into the skins are not displayed.
When we turn on 2 skin, sprites are shown and bones do not appear what to do?

Code that adds a skin to an object

    Related Discussions
    ...

    Ali I'm sorry to hear you're having trouble. Unfortunately, I cannot figure out the cause of the problem just from the code in the image. I think you are at least using the correct method to set a skin, but the problem seems to be that the skin bones are not reflected correctly, so we should start by making sure your skeleton setup is correct in the first place. If you don't mind, could you send us that Spine project via email?: contact@esotericsoftware.com
    The project you send us can be with only part of the skeleton left and the rest removed, as long as we can reproduce the problem. You can also replace the skeleton images with other ones, if you would like to.

    Hello, I'm a colleague in charge of the code.

    And the problem turned out to be in it, you described above that most likely the executable code is correct, but not quite, for some reason I did not find information that after installing the skin, you need to call the method
    UpdateCache()

    He helped, maybe this is superfluous and the problem is different?

    I understand correctly that the UpdateCache() method
    Was it created specifically for such purposes?

    Namely, if the location of the bones changes in the skins or restrictions are imposed?

    Thanks in advance for your reply.

      TheZero Sorry for the delay in response! I realized that you had sent us your Spine project files.

      As far as I have imported the exported files you sent us into a new Unity project and set it with a combined skin of car and user skins, the skin bone seems to be working fine, even if I do not use UpdateCache() method.

      By the way, there are warnings on two transform constraints in your Spine project: 1 and 3.
      When a constraint has a warning, it means that it either cannot be applied at all, or can only be applied sometimes, depending on which skins are visible. I suspect that this is the cause of the skin bone not working in your Unity project. It seems that both warnings can be resolved by adding them to the Car_2/Car_2 skin, so could you please check if that works?

      7 días más tarde

      I'm sorry too, I've been a bit busy.

      Unfortunately, time does not allow us to verify what you are asking.

      If there is free time, I will ask the animator to correct these moments, if he wishes.
      And I will test it in the project.

      UpdateCache() method.

      While coping.
      But it would be interesting for me to find out if the problem is really in the errors of the Spine project.

      Because it came to me on the go to supplement the plugin written by me for more convenient use of Spine in unity