• Unity
  • Runtime error! Are the masks to blame?

Runtime error
if a mask is used in the skeleton, an error occurs!
there was no such problem before, it is difficult to say exactly with which version it started, a month ago and earlier - such a problem was not observed!
Now, if I completely remove masks from all skeletons of the project and export the project, then after importing into unity no errors occur
how to live without masks? :scared:
please check if skeletons with masks are exported correctly.

NullReferenceException: Object reference not set to an instance of an object
Spine.Unity.MeshGenerator.AddSubmesh (Spine.Unity.SubmeshInstruction instruction, System.Boolean updateTriangles) (at Assets/External/SpineAnimation/Spine/Runtime/spine-unity/Mesh Generation/MeshGenerator.cs:490)
Spine.Unity.SkeletonRenderer.LateUpdate () (at Assets/External/SpineAnimation/Spine/Runtime/spine-unity/Components/SkeletonRenderer.cs:429)
Spine.Unity.SkeletonAnimation.LateUpdate () (at Assets/External/SpineAnimation/Spine/Runtime/spine-unity/Components/SkeletonAnimation.cs:247)

p.s.
Spine Pro 4.0.51

    Related Discussions
    ...
    • Düzenlendi

    Sorry for the troubles! Are you sure that you mean "mask" in terms of a Unity Mask component (on the Unity side), or do you mean a Clipping Attachment in the Spine Editor?

    Which version of the spine-unity runtime (name of the unitypackage, also in version.txt file) are you using?

    I use Clipping Attachment in the Spine Editor.
    Package version: spine-unity-4.0-2021-07-27.unitypackage

    Thanks for the follow up. Export with Clipping Attachments is working as expected on our end.

    We have released multiple bugfixes since package version 2021-07-27, could you please have a try if upgrading the spine-unity runtime package resolves your problem? If you need to stay on this runtime version, you could perform a quick test in a new empty project, or create a backup project.

    8 ay sonra

    Hi
    I just got the same problem. I use Spine 3.8.98 and Unity-Spine runtime 3.8
    I needed to remove all the masks to get rid of the same error while using Skeleton Graphics

    Could you please send us the problematic Spine project (the project file including the required attachment images)? You can send it as a zip package to contact@esotericsoftware.com, briefly mentioning this forum thread URL so that we know the context.

    7 ay sonra

    Artfrost
    I've encountered the same issue today, and managed to solve this by going to my Spine animation (Setup mode) and change the attachment into a mesh. (Instead of an image).

    Sorry to hear you were having troubles! If this issue still exists in the runtime, we would really like to fix it, such workarounds should obviously never be necessary. Which version of the spine-unity runtime (name of the unitypackage, also listed in Assets/Spine/Version.txt) are you using?

    Thanks for the fast reply! I'm using spine-unity-3.8-2020-09-03
    My spine version is 3.8.99.