- Modifié
unity同一场景中复制spine动画模型图片显示出错
在场景中,选中spine模型,Ctrl + D 复制模型,两个模型就会出现图片缺失、层级错位等现象。
请问大神解决办法。
抱歉,您遇到了麻烦。我们还没有遇到过这样的问题。 您使用的是哪个版本的 spin-unity 运行时(unitypackage 的名称,也在 Assets/Spine/version.txt
中列出)?
Sorry that you're having troubles. We have not yet encountered such an issue. Which version of the spine-unity runtime (name of the unitypackage, also listed in Assets/Spine/version.txt
) are you using?
Harald a écrit
感谢您的回复,我的spine-unity是spine-unity-4.0-2022-01-10.unitypackage。
txt:This Spine-Unity runtime works with data exported from Spine Editor version: 4.0.xx
Package version: spine-unity-4.0-2022-01-10.unitypackage
感谢您提供后续信息。
自从软件包版本spine-unity-4.0-2022-01-10
以来已经发布了许多错误修正,你看看最新的4.0 unitypackage是否仍然有这个错误? 像往常一样,请务必在升级之前备份您的项目。
Thanks for the follow up information.
Many bugfixes have been released since package version spine-unity-4.0-2022-01-10
, did you have a look whether the latest 4.0 unitypackage still has this error? As usual, please be sure to backup your project before upgrading.
Harald a écrit感谢您提供后续信息。
自从软件包版本
spine-unity-4.0-2022-01-10
以来已经发布了许多错误修正,你看看最新的4.0 unitypackage是否仍然有这个错误? 像往常一样,请务必在升级之前备份您的项目。
Thanks for the follow up information.
Many bugfixes have been released since package version
spine-unity-4.0-2022-01-10
, did you have a look whether the latest 4.0 unitypackage still has this error? As usual, please be sure to backup your project before upgrading.
感谢您的回复,我将unity-spine升级为了4.0 2022-09-26 ,但问题仍然存在,当场景中存在多个同一模型时,我发现只有一个或两个模型时并不会出错,当模型数量大于2时,就开始出现层级错误的问题,比如有时眼睛会消失(眼睛层级低于头部层级),或者大臂与小臂的层级、手与身体的层级等,会出现时而层级正确,时而错误的情况,所以看起来模型是一闪一闪的。我不知道这是否与我的模型的skin数量很多有关系,我的模型拥有上百个skin。但是多个spine资产可以同时存在于场景中,不会出错,只是同一个spine资产在场景中重复出现时就会出错。
感谢您的附加信息。 这听起来好像每个骨架有多个图集页面(多种材料),并且批处理将它们重新排序为错误的分组顺序。
可能的解决方案是:
- 您可以为每个骨架游戏对象添加一个 SortingGroup 组件。
- 尝试启用
SkeletonAnimation
检查器属性Advanced
-Fix Draw Order
。 请参阅脊柱统一文档页面 这里。 - 将所有内容都放在单个地图集页面纹理上。 那么就不需要通过批处理器重新组合任何东西,它会保持原样。
Thanks for the additional information. This sounds as if you have multiple atlas pages (multiple materials) per skeleton and batching is reordering them to an incorrectly grouped order.
Possible solutions are:
- You can add a SortingGroup component to each skeleton GameObject.
- Try to enable the
SkeletonAnimation
Inspector propertyAdvanced
-Fix Draw Order
. See spine-unity documentation page here. - To have everything on a single atlas page texture. Then there is no need to re-group anything by the batcher, and it will keep the order as-is.
Harald a écrit感谢您的附加信息。 这听起来好像每个骨架有多个图集页面(多种材料),并且批处理将它们重新排序为错误的分组顺序。
可能的解决方案是:
- 您可以为每个骨架游戏对象添加一个 SortingGroup 组件。
- 尝试启用
SkeletonAnimation
检查器属性Advanced
-Fix Draw Order
。 请参阅脊柱统一文档页面 这里。- 将所有内容都放在单个地图集页面纹理上。 那么就不需要通过批处理器重新组合任何东西,它会保持原样。
Thanks for the additional information. This sounds as if you have multiple atlas pages (multiple materials) per skeleton and batching is reordering them to an incorrectly grouped order.
Possible solutions are:
- You can add a SortingGroup component to each skeleton GameObject.
- Try to enable the
SkeletonAnimation
Inspector propertyAdvanced
-Fix Draw Order
. See spine-unity documentation page here.- To have everything on a single atlas page texture. Then there is no need to re-group anything by the batcher, and it will keep the order as-is.
非常感谢您的回复,通过添加SortingGroup组件解决了我的问题,祝您一切顺利。
很高兴听到,感谢您回复我们。
Very glad to hear, thanks for getting back to us.