浏览代码

[unity] SkeletonUtility method for delaying its update order forward.

pharan 6 年之前
父节点
当前提交
aa0dcee09a
共有 1 个文件被更改,包括 5 次插入0 次删除
  1. 5 0
      spine-unity/Assets/Spine/Runtime/spine-unity/SkeletonUtility/SkeletonUtility.cs

+ 5 - 0
spine-unity/Assets/Spine/Runtime/spine-unity/SkeletonUtility/SkeletonUtility.cs

@@ -136,6 +136,11 @@ namespace Spine.Unity {
 		bool hasConstraints;
 		bool needToReprocessBones;
 
+		public void ResubscribeEvents () {
+			OnDisable();
+			OnEnable();
+		}
+		
 		void OnEnable () {
 			if (skeletonRenderer == null) {
 				skeletonRenderer = GetComponent<SkeletonRenderer>();