Forráskód Böngészése

[unity] Reorganize folders for asmdef compatibility. Remove old files.

pharan 7 éve
szülő
commit
065a10f4b3
100 módosított fájl, 897 hozzáadás és 888 törlés
  1. 2 2
      spine-unity/Assets/Spine.meta
  2. 2 2
      spine-unity/Assets/Spine/Editor.meta
  3. 9 0
      spine-unity/Assets/Spine/Editor/spine-unity.meta
  4. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor.meta
  5. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/AnimationReferenceAssetEditor.cs
  6. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/AnimationReferenceAssetEditor.cs.meta
  7. 51 51
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/AssetDatabaseAvailabilityDetector.cs
  8. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/AssetDatabaseAvailabilityDetector.cs.meta
  9. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/AtlasAssetInspector.cs
  10. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/AtlasAssetInspector.cs.meta
  11. 208 208
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/BoneFollowerInspector.cs
  12. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/BoneFollowerInspector.cs.meta
  13. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI.meta
  14. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/AtlasAsset Icon.png
  15. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/AtlasAsset Icon.png.meta
  16. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/SkeletonDataAsset Icon.png
  17. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/SkeletonDataAsset Icon.png.meta
  18. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-animation.png
  19. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-animation.png.meta
  20. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-animationRoot.png
  21. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-animationRoot.png.meta
  22. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-attachment.png
  23. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-attachment.png.meta
  24. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-bone.png
  25. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-bone.png.meta
  26. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-boneNib.png
  27. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-boneNib.png.meta
  28. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-boundingBox.png
  29. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-boundingBox.png.meta
  30. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-clipping.png
  31. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-clipping.png.meta
  32. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-constraintIK.png
  33. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-constraintIK.png.meta
  34. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-constraintNib.png
  35. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-constraintNib.png.meta
  36. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-constraintPath.png
  37. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-constraintPath.png.meta
  38. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-constraintTransform.png
  39. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-constraintTransform.png.meta
  40. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-constraints.png
  41. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-constraints.png.meta
  42. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-event.png
  43. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-event.png.meta
  44. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-hingeChain.png
  45. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-hingeChain.png.meta
  46. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-image.png
  47. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-image.png.meta
  48. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-mesh.png
  49. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-mesh.png.meta
  50. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-null.png
  51. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-null.png.meta
  52. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-path.png
  53. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-path.png.meta
  54. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-point.png
  55. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-point.png.meta
  56. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-poseBones.png
  57. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-poseBones.png.meta
  58. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-skeleton.png
  59. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-skeleton.png.meta
  60. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-skeletonUtility.png
  61. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-skeletonUtility.png.meta
  62. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-skin.png
  63. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-skin.png.meta
  64. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-skinPlaceholder.png
  65. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-skinPlaceholder.png.meta
  66. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-skinsRoot.png
  67. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-skinsRoot.png.meta
  68. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-slot.png
  69. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-slot.png.meta
  70. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-slotRoot.png
  71. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-slotRoot.png.meta
  72. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-spine.png
  73. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-spine.png.meta
  74. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-subMeshRenderer.png
  75. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-subMeshRenderer.png.meta
  76. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-warning.png
  77. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-warning.png.meta
  78. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-weights.png
  79. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-weights.png.meta
  80. 84 84
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/Menus.cs
  81. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/Menus.cs.meta
  82. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/PointFollowerEditor.cs
  83. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/PointFollowerEditor.cs.meta
  84. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/Resources.meta
  85. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/Resources/SpineAssetDatabaseMarker.txt
  86. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/Resources/SpineAssetDatabaseMarker.txt.meta
  87. 143 143
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/SkeletonAnimationInspector.cs
  88. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/SkeletonAnimationInspector.cs.meta
  89. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/SkeletonAnimatorInspector.cs
  90. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/SkeletonAnimatorInspector.cs.meta
  91. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/SkeletonBaker.cs
  92. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/SkeletonBaker.cs.meta
  93. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/SkeletonBakingWindow.cs
  94. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/SkeletonBakingWindow.cs.meta
  95. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/SkeletonDataAssetInspector.cs
  96. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/SkeletonDataAssetInspector.cs.meta
  97. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/SkeletonDebugWindow.cs
  98. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/SkeletonDebugWindow.cs.meta
  99. 398 398
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/SkeletonRendererInspector.cs
  100. 0 0
      spine-unity/Assets/Spine/Editor/spine-unity/Editor/SkeletonRendererInspector.cs.meta

+ 2 - 2
spine-unity/Assets/spine-unity/Mesh Generation/Unused.meta → spine-unity/Assets/Spine.meta

@@ -1,7 +1,7 @@
 fileFormatVersion: 2
-guid: 0cb4e560224445d44affd8e57c1ae8b1
+guid: 30918bcaadaaecc42bc215ff52f75b21
 folderAsset: yes
-timeCreated: 1495071888
+timeCreated: 1488288531
 licenseType: Free
 DefaultImporter:
   userData: 

+ 2 - 2
spine-unity/Assets/spine-unity/Modules/Timeline/SpineSkeletonFlip/Editor.meta → spine-unity/Assets/Spine/Editor.meta

@@ -1,7 +1,7 @@
 fileFormatVersion: 2
-guid: fc5fac7eface2ba4fbb6146017e41192
+guid: ad14d5a4cd7a0444286d315541ee0495
 folderAsset: yes
-timeCreated: 1500876410
+timeCreated: 1527569319
 licenseType: Free
 DefaultImporter:
   userData: 

+ 9 - 0
spine-unity/Assets/Spine/Editor/spine-unity.meta

@@ -0,0 +1,9 @@
+fileFormatVersion: 2
+guid: 83fbec88df35fe34bab43a5dde6788af
+folderAsset: yes
+timeCreated: 1527569675
+licenseType: Free
+DefaultImporter:
+  userData: 
+  assetBundleName: 
+  assetBundleVariant: 

+ 0 - 0
spine-unity/Assets/spine-unity/Editor.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor.meta


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/AnimationReferenceAssetEditor.cs → spine-unity/Assets/Spine/Editor/spine-unity/Editor/AnimationReferenceAssetEditor.cs


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/AnimationReferenceAssetEditor.cs.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/AnimationReferenceAssetEditor.cs.meta


+ 51 - 51
spine-unity/Assets/spine-unity/Editor/AssetDatabaseAvailabilityDetector.cs → spine-unity/Assets/Spine/Editor/spine-unity/Editor/AssetDatabaseAvailabilityDetector.cs

@@ -1,51 +1,51 @@
-/******************************************************************************
- * Spine Runtimes Software License v2.5
- *
- * Copyright (c) 2013-2016, Esoteric Software
- * All rights reserved.
- *
- * You are granted a perpetual, non-exclusive, non-sublicensable, and
- * non-transferable license to use, install, execute, and perform the Spine
- * Runtimes software and derivative works solely for personal or internal
- * use. Without the written permission of Esoteric Software (see Section 2 of
- * the Spine Software License Agreement), you may not (a) modify, translate,
- * adapt, or develop new applications using the Spine Runtimes or otherwise
- * create derivative works or improvements of the Spine Runtimes or (b) remove,
- * delete, alter, or obscure any trademarks or any copyright, trademark, patent,
- * or other intellectual property or proprietary rights notices on or in the
- * Software, including any copy thereof. Redistributions in binary or source
- * form must include this license and terms.
- *
- * THIS SOFTWARE IS PROVIDED BY ESOTERIC SOFTWARE "AS IS" AND ANY EXPRESS OR
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
- * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
- * EVENT SHALL ESOTERIC SOFTWARE BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES, BUSINESS INTERRUPTION, OR LOSS OF
- * USE, DATA, OR PROFITS) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
- * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
- * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
- * POSSIBILITY OF SUCH DAMAGE.
- *****************************************************************************/
-
-using UnityEngine;
-
-namespace Spine.Unity.Editor {
-	public static class AssetDatabaseAvailabilityDetector {
-		const string MARKER_RESOURCE_NAME = "SpineAssetDatabaseMarker";
-		private static bool _isMarkerLoaded;
-
-		public static bool IsAssetDatabaseAvailable (bool forceCheck = false) {
-			if (!forceCheck && _isMarkerLoaded)
-				return true;
-
-			TextAsset markerTextAsset = Resources.Load<TextAsset>(MARKER_RESOURCE_NAME);
-			_isMarkerLoaded = markerTextAsset != null;
-			if (markerTextAsset != null) {
-				Resources.UnloadAsset(markerTextAsset);
-			}
-
-			return _isMarkerLoaded;
-		}
-	}
-}
+/******************************************************************************
+ * Spine Runtimes Software License v2.5
+ *
+ * Copyright (c) 2013-2016, Esoteric Software
+ * All rights reserved.
+ *
+ * You are granted a perpetual, non-exclusive, non-sublicensable, and
+ * non-transferable license to use, install, execute, and perform the Spine
+ * Runtimes software and derivative works solely for personal or internal
+ * use. Without the written permission of Esoteric Software (see Section 2 of
+ * the Spine Software License Agreement), you may not (a) modify, translate,
+ * adapt, or develop new applications using the Spine Runtimes or otherwise
+ * create derivative works or improvements of the Spine Runtimes or (b) remove,
+ * delete, alter, or obscure any trademarks or any copyright, trademark, patent,
+ * or other intellectual property or proprietary rights notices on or in the
+ * Software, including any copy thereof. Redistributions in binary or source
+ * form must include this license and terms.
+ *
+ * THIS SOFTWARE IS PROVIDED BY ESOTERIC SOFTWARE "AS IS" AND ANY EXPRESS OR
+ * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+ * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
+ * EVENT SHALL ESOTERIC SOFTWARE BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+ * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES, BUSINESS INTERRUPTION, OR LOSS OF
+ * USE, DATA, OR PROFITS) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
+ * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+ * POSSIBILITY OF SUCH DAMAGE.
+ *****************************************************************************/
+
+using UnityEngine;
+
+namespace Spine.Unity.Editor {
+	public static class AssetDatabaseAvailabilityDetector {
+		const string MARKER_RESOURCE_NAME = "SpineAssetDatabaseMarker";
+		private static bool _isMarkerLoaded;
+
+		public static bool IsAssetDatabaseAvailable (bool forceCheck = false) {
+			if (!forceCheck && _isMarkerLoaded)
+				return true;
+
+			TextAsset markerTextAsset = Resources.Load<TextAsset>(MARKER_RESOURCE_NAME);
+			_isMarkerLoaded = markerTextAsset != null;
+			if (markerTextAsset != null) {
+				Resources.UnloadAsset(markerTextAsset);
+			}
+
+			return _isMarkerLoaded;
+		}
+	}
+}

+ 0 - 0
spine-unity/Assets/spine-unity/Editor/AssetDatabaseAvailabilityDetector.cs.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/AssetDatabaseAvailabilityDetector.cs.meta


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/AtlasAssetInspector.cs → spine-unity/Assets/Spine/Editor/spine-unity/Editor/AtlasAssetInspector.cs


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/AtlasAssetInspector.cs.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/AtlasAssetInspector.cs.meta


+ 208 - 208
spine-unity/Assets/spine-unity/Editor/BoneFollowerInspector.cs → spine-unity/Assets/Spine/Editor/spine-unity/Editor/BoneFollowerInspector.cs

@@ -1,208 +1,208 @@
-/******************************************************************************
- * Spine Runtimes Software License v2.5
- *
- * Copyright (c) 2013-2016, Esoteric Software
- * All rights reserved.
- *
- * You are granted a perpetual, non-exclusive, non-sublicensable, and
- * non-transferable license to use, install, execute, and perform the Spine
- * Runtimes software and derivative works solely for personal or internal
- * use. Without the written permission of Esoteric Software (see Section 2 of
- * the Spine Software License Agreement), you may not (a) modify, translate,
- * adapt, or develop new applications using the Spine Runtimes or otherwise
- * create derivative works or improvements of the Spine Runtimes or (b) remove,
- * delete, alter, or obscure any trademarks or any copyright, trademark, patent,
- * or other intellectual property or proprietary rights notices on or in the
- * Software, including any copy thereof. Redistributions in binary or source
- * form must include this license and terms.
- *
- * THIS SOFTWARE IS PROVIDED BY ESOTERIC SOFTWARE "AS IS" AND ANY EXPRESS OR
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
- * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
- * EVENT SHALL ESOTERIC SOFTWARE BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES, BUSINESS INTERRUPTION, OR LOSS OF
- * USE, DATA, OR PROFITS) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
- * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
- * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
- * POSSIBILITY OF SUCH DAMAGE.
- *****************************************************************************/
-
-using UnityEditor;
-using UnityEngine;
-
-namespace Spine.Unity.Editor {
-
-	using Editor = UnityEditor.Editor;
-	using Event = UnityEngine.Event;
-
-	[CustomEditor(typeof(BoneFollower)), CanEditMultipleObjects]
-	public class BoneFollowerInspector : Editor {
-		SerializedProperty boneName, skeletonRenderer, followZPosition, followBoneRotation, followLocalScale, followSkeletonFlip;
-		BoneFollower targetBoneFollower;
-		bool needsReset;
-
-		#region Context Menu Item
-		[MenuItem ("CONTEXT/SkeletonRenderer/Add BoneFollower GameObject")]
-		static void AddBoneFollowerGameObject (MenuCommand cmd) {
-			var skeletonRenderer = cmd.context as SkeletonRenderer;
-			var go = new GameObject("BoneFollower");
-			var t = go.transform;
-			t.SetParent(skeletonRenderer.transform);
-			t.localPosition = Vector3.zero;
-
-			var f = go.AddComponent<BoneFollower>();
-			f.skeletonRenderer = skeletonRenderer;
-
-			EditorGUIUtility.PingObject(t);
-
-			Undo.RegisterCreatedObjectUndo(go, "Add BoneFollower");
-		}
-
-		// Validate
-		[MenuItem ("CONTEXT/SkeletonRenderer/Add BoneFollower GameObject", true)]
-		static bool ValidateAddBoneFollowerGameObject (MenuCommand cmd) {
-			var skeletonRenderer = cmd.context as SkeletonRenderer;
-			return skeletonRenderer.valid;
-		}
-		#endregion
-
-		void OnEnable () {
-			skeletonRenderer = serializedObject.FindProperty("skeletonRenderer");
-			boneName = serializedObject.FindProperty("boneName");
-			followBoneRotation = serializedObject.FindProperty("followBoneRotation");
-			followZPosition = serializedObject.FindProperty("followZPosition");
-			followLocalScale = serializedObject.FindProperty("followLocalScale");
-			followSkeletonFlip = serializedObject.FindProperty("followSkeletonFlip");
-
-			targetBoneFollower = (BoneFollower)target;
-			if (targetBoneFollower.SkeletonRenderer != null)
-				targetBoneFollower.SkeletonRenderer.Initialize(false);
-
-			if (!targetBoneFollower.valid || needsReset) {
-				targetBoneFollower.Initialize();
-				targetBoneFollower.LateUpdate();
-				needsReset = false;
-				SceneView.RepaintAll();
-			}
-		}
-
-		public void OnSceneGUI () {
-			var tbf = target as BoneFollower;
-			var skeletonRendererComponent = tbf.skeletonRenderer;
-			if (skeletonRendererComponent == null) return;
-
-			var transform = skeletonRendererComponent.transform;
-			var skeleton = skeletonRendererComponent.skeleton;
-
-			if (string.IsNullOrEmpty(boneName.stringValue)) {
-				SpineHandles.DrawBones(transform, skeleton);
-				SpineHandles.DrawBoneNames(transform, skeleton);
-				Handles.Label(tbf.transform.position, "No bone selected", EditorStyles.helpBox);
-			} else {
-				var targetBone = tbf.bone;
-				if (targetBone == null) return;
-				SpineHandles.DrawBoneWireframe(transform, targetBone, SpineHandles.TransformContraintColor);
-				Handles.Label(targetBone.GetWorldPosition(transform), targetBone.Data.Name, SpineHandles.BoneNameStyle);
-			}
-		}
-
-		override public void OnInspectorGUI () {
-			if (serializedObject.isEditingMultipleObjects) {
-				if (needsReset) {
-					needsReset = false;
-					foreach (var o in targets) {
-						var bf = (BoneFollower)o;
-						bf.Initialize();
-						bf.LateUpdate();
-					}
-					SceneView.RepaintAll();
-				}
-
-				EditorGUI.BeginChangeCheck();
-				DrawDefaultInspector();
-				needsReset |= EditorGUI.EndChangeCheck();
-				return;
-			}
-
-			if (needsReset && Event.current.type == EventType.Layout) {
-				targetBoneFollower.Initialize();
-				targetBoneFollower.LateUpdate();
-				needsReset = false;
-				SceneView.RepaintAll();
-			}
-			serializedObject.Update();
-
-			// Find Renderer
-			if (skeletonRenderer.objectReferenceValue == null) {
-				SkeletonRenderer parentRenderer = targetBoneFollower.GetComponentInParent<SkeletonRenderer>();
-				if (parentRenderer != null && parentRenderer.gameObject != targetBoneFollower.gameObject) {
-					skeletonRenderer.objectReferenceValue = parentRenderer;
-					Debug.Log("Inspector automatically assigned BoneFollower.SkeletonRenderer");
-				}
-			}
-
-			EditorGUILayout.PropertyField(skeletonRenderer);
-			var skeletonRendererReference = skeletonRenderer.objectReferenceValue as SkeletonRenderer;
-			if (skeletonRendererReference != null) {
-				if (skeletonRendererReference.gameObject == targetBoneFollower.gameObject) {
-					skeletonRenderer.objectReferenceValue = null;
-					EditorUtility.DisplayDialog("Invalid assignment.", "BoneFollower can only follow a skeleton on a separate GameObject.\n\nCreate a new GameObject for your BoneFollower, or choose a SkeletonRenderer from a different GameObject.", "Ok");
-				}
-			}
-
-			if (!targetBoneFollower.valid) {
-				needsReset = true;
-			}
-
-			if (targetBoneFollower.valid) {
-				EditorGUI.BeginChangeCheck();
-				EditorGUILayout.PropertyField(boneName);
-				needsReset |= EditorGUI.EndChangeCheck();
-
-				EditorGUILayout.PropertyField(followBoneRotation);
-				EditorGUILayout.PropertyField(followZPosition);
-				EditorGUILayout.PropertyField(followLocalScale);
-				EditorGUILayout.PropertyField(followSkeletonFlip);
-
-				BoneFollowerInspector.RecommendRigidbodyButton(targetBoneFollower);
-			} else {
-				var boneFollowerSkeletonRenderer = targetBoneFollower.skeletonRenderer;
-				if (boneFollowerSkeletonRenderer == null) {
-					EditorGUILayout.HelpBox("SkeletonRenderer is unassigned. Please assign a SkeletonRenderer (SkeletonAnimation or SkeletonAnimator).", MessageType.Warning);
-				} else {
-					boneFollowerSkeletonRenderer.Initialize(false);
-
-					if (boneFollowerSkeletonRenderer.skeletonDataAsset == null)
-						EditorGUILayout.HelpBox("Assigned SkeletonRenderer does not have SkeletonData assigned to it.", MessageType.Warning);
-
-					if (!boneFollowerSkeletonRenderer.valid)
-						EditorGUILayout.HelpBox("Assigned SkeletonRenderer is invalid. Check target SkeletonRenderer, its SkeletonDataAsset or the console for other errors.", MessageType.Warning);
-				}
-			}
-
-			var current = Event.current;
-			bool wasUndo = (current.type == EventType.ValidateCommand && current.commandName == "UndoRedoPerformed");
-			if (wasUndo)
-				targetBoneFollower.Initialize();
-
-			serializedObject.ApplyModifiedProperties();
-		}
-
-		internal static void RecommendRigidbodyButton (Component component) {
-			bool hasCollider2D = component.GetComponent<Collider2D>() != null || component.GetComponent<BoundingBoxFollower>() != null;
-			bool hasCollider3D = !hasCollider2D && component.GetComponent<Collider>();
-			bool missingRigidBody = (hasCollider2D && component.GetComponent<Rigidbody2D>() == null) || (hasCollider3D && component.GetComponent<Rigidbody>() == null);
-			if (missingRigidBody) {
-				using (new SpineInspectorUtility.BoxScope()) {
-					EditorGUILayout.HelpBox("Collider detected. Unity recommends adding a Rigidbody to the parent Transforms of any colliders that are intended to be dynamically repositioned and rotated.", MessageType.Warning);
-					var rbType = hasCollider2D ? typeof(Rigidbody2D) : typeof(Rigidbody);
-					string rbLabel = string.Format("Add {0}", rbType.Name);
-					var rbContent = SpineInspectorUtility.TempContent(rbLabel, SpineInspectorUtility.UnityIcon(rbType), "Add a rigidbody to this GameObject to be the Physics body parent of the attached collider.");
-					if (SpineInspectorUtility.CenteredButton(rbContent)) component.gameObject.AddComponent(rbType);
-				}
-			}
-		}
-	}
-
-}
+/******************************************************************************
+ * Spine Runtimes Software License v2.5
+ *
+ * Copyright (c) 2013-2016, Esoteric Software
+ * All rights reserved.
+ *
+ * You are granted a perpetual, non-exclusive, non-sublicensable, and
+ * non-transferable license to use, install, execute, and perform the Spine
+ * Runtimes software and derivative works solely for personal or internal
+ * use. Without the written permission of Esoteric Software (see Section 2 of
+ * the Spine Software License Agreement), you may not (a) modify, translate,
+ * adapt, or develop new applications using the Spine Runtimes or otherwise
+ * create derivative works or improvements of the Spine Runtimes or (b) remove,
+ * delete, alter, or obscure any trademarks or any copyright, trademark, patent,
+ * or other intellectual property or proprietary rights notices on or in the
+ * Software, including any copy thereof. Redistributions in binary or source
+ * form must include this license and terms.
+ *
+ * THIS SOFTWARE IS PROVIDED BY ESOTERIC SOFTWARE "AS IS" AND ANY EXPRESS OR
+ * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+ * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
+ * EVENT SHALL ESOTERIC SOFTWARE BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+ * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES, BUSINESS INTERRUPTION, OR LOSS OF
+ * USE, DATA, OR PROFITS) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
+ * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+ * POSSIBILITY OF SUCH DAMAGE.
+ *****************************************************************************/
+
+using UnityEditor;
+using UnityEngine;
+
+namespace Spine.Unity.Editor {
+
+	using Editor = UnityEditor.Editor;
+	using Event = UnityEngine.Event;
+
+	[CustomEditor(typeof(BoneFollower)), CanEditMultipleObjects]
+	public class BoneFollowerInspector : Editor {
+		SerializedProperty boneName, skeletonRenderer, followZPosition, followBoneRotation, followLocalScale, followSkeletonFlip;
+		BoneFollower targetBoneFollower;
+		bool needsReset;
+
+		#region Context Menu Item
+		[MenuItem ("CONTEXT/SkeletonRenderer/Add BoneFollower GameObject")]
+		static void AddBoneFollowerGameObject (MenuCommand cmd) {
+			var skeletonRenderer = cmd.context as SkeletonRenderer;
+			var go = new GameObject("BoneFollower");
+			var t = go.transform;
+			t.SetParent(skeletonRenderer.transform);
+			t.localPosition = Vector3.zero;
+
+			var f = go.AddComponent<BoneFollower>();
+			f.skeletonRenderer = skeletonRenderer;
+
+			EditorGUIUtility.PingObject(t);
+
+			Undo.RegisterCreatedObjectUndo(go, "Add BoneFollower");
+		}
+
+		// Validate
+		[MenuItem ("CONTEXT/SkeletonRenderer/Add BoneFollower GameObject", true)]
+		static bool ValidateAddBoneFollowerGameObject (MenuCommand cmd) {
+			var skeletonRenderer = cmd.context as SkeletonRenderer;
+			return skeletonRenderer.valid;
+		}
+		#endregion
+
+		void OnEnable () {
+			skeletonRenderer = serializedObject.FindProperty("skeletonRenderer");
+			boneName = serializedObject.FindProperty("boneName");
+			followBoneRotation = serializedObject.FindProperty("followBoneRotation");
+			followZPosition = serializedObject.FindProperty("followZPosition");
+			followLocalScale = serializedObject.FindProperty("followLocalScale");
+			followSkeletonFlip = serializedObject.FindProperty("followSkeletonFlip");
+
+			targetBoneFollower = (BoneFollower)target;
+			if (targetBoneFollower.SkeletonRenderer != null)
+				targetBoneFollower.SkeletonRenderer.Initialize(false);
+
+			if (!targetBoneFollower.valid || needsReset) {
+				targetBoneFollower.Initialize();
+				targetBoneFollower.LateUpdate();
+				needsReset = false;
+				SceneView.RepaintAll();
+			}
+		}
+
+		public void OnSceneGUI () {
+			var tbf = target as BoneFollower;
+			var skeletonRendererComponent = tbf.skeletonRenderer;
+			if (skeletonRendererComponent == null) return;
+
+			var transform = skeletonRendererComponent.transform;
+			var skeleton = skeletonRendererComponent.skeleton;
+
+			if (string.IsNullOrEmpty(boneName.stringValue)) {
+				SpineHandles.DrawBones(transform, skeleton);
+				SpineHandles.DrawBoneNames(transform, skeleton);
+				Handles.Label(tbf.transform.position, "No bone selected", EditorStyles.helpBox);
+			} else {
+				var targetBone = tbf.bone;
+				if (targetBone == null) return;
+				SpineHandles.DrawBoneWireframe(transform, targetBone, SpineHandles.TransformContraintColor);
+				Handles.Label(targetBone.GetWorldPosition(transform), targetBone.Data.Name, SpineHandles.BoneNameStyle);
+			}
+		}
+
+		override public void OnInspectorGUI () {
+			if (serializedObject.isEditingMultipleObjects) {
+				if (needsReset) {
+					needsReset = false;
+					foreach (var o in targets) {
+						var bf = (BoneFollower)o;
+						bf.Initialize();
+						bf.LateUpdate();
+					}
+					SceneView.RepaintAll();
+				}
+
+				EditorGUI.BeginChangeCheck();
+				DrawDefaultInspector();
+				needsReset |= EditorGUI.EndChangeCheck();
+				return;
+			}
+
+			if (needsReset && Event.current.type == EventType.Layout) {
+				targetBoneFollower.Initialize();
+				targetBoneFollower.LateUpdate();
+				needsReset = false;
+				SceneView.RepaintAll();
+			}
+			serializedObject.Update();
+
+			// Find Renderer
+			if (skeletonRenderer.objectReferenceValue == null) {
+				SkeletonRenderer parentRenderer = targetBoneFollower.GetComponentInParent<SkeletonRenderer>();
+				if (parentRenderer != null && parentRenderer.gameObject != targetBoneFollower.gameObject) {
+					skeletonRenderer.objectReferenceValue = parentRenderer;
+					Debug.Log("Inspector automatically assigned BoneFollower.SkeletonRenderer");
+				}
+			}
+
+			EditorGUILayout.PropertyField(skeletonRenderer);
+			var skeletonRendererReference = skeletonRenderer.objectReferenceValue as SkeletonRenderer;
+			if (skeletonRendererReference != null) {
+				if (skeletonRendererReference.gameObject == targetBoneFollower.gameObject) {
+					skeletonRenderer.objectReferenceValue = null;
+					EditorUtility.DisplayDialog("Invalid assignment.", "BoneFollower can only follow a skeleton on a separate GameObject.\n\nCreate a new GameObject for your BoneFollower, or choose a SkeletonRenderer from a different GameObject.", "Ok");
+				}
+			}
+
+			if (!targetBoneFollower.valid) {
+				needsReset = true;
+			}
+
+			if (targetBoneFollower.valid) {
+				EditorGUI.BeginChangeCheck();
+				EditorGUILayout.PropertyField(boneName);
+				needsReset |= EditorGUI.EndChangeCheck();
+
+				EditorGUILayout.PropertyField(followBoneRotation);
+				EditorGUILayout.PropertyField(followZPosition);
+				EditorGUILayout.PropertyField(followLocalScale);
+				EditorGUILayout.PropertyField(followSkeletonFlip);
+
+				BoneFollowerInspector.RecommendRigidbodyButton(targetBoneFollower);
+			} else {
+				var boneFollowerSkeletonRenderer = targetBoneFollower.skeletonRenderer;
+				if (boneFollowerSkeletonRenderer == null) {
+					EditorGUILayout.HelpBox("SkeletonRenderer is unassigned. Please assign a SkeletonRenderer (SkeletonAnimation or SkeletonAnimator).", MessageType.Warning);
+				} else {
+					boneFollowerSkeletonRenderer.Initialize(false);
+
+					if (boneFollowerSkeletonRenderer.skeletonDataAsset == null)
+						EditorGUILayout.HelpBox("Assigned SkeletonRenderer does not have SkeletonData assigned to it.", MessageType.Warning);
+
+					if (!boneFollowerSkeletonRenderer.valid)
+						EditorGUILayout.HelpBox("Assigned SkeletonRenderer is invalid. Check target SkeletonRenderer, its SkeletonDataAsset or the console for other errors.", MessageType.Warning);
+				}
+			}
+
+			var current = Event.current;
+			bool wasUndo = (current.type == EventType.ValidateCommand && current.commandName == "UndoRedoPerformed");
+			if (wasUndo)
+				targetBoneFollower.Initialize();
+
+			serializedObject.ApplyModifiedProperties();
+		}
+
+		internal static void RecommendRigidbodyButton (Component component) {
+			bool hasCollider2D = component.GetComponent<Collider2D>() != null || component.GetComponent<BoundingBoxFollower>() != null;
+			bool hasCollider3D = !hasCollider2D && component.GetComponent<Collider>();
+			bool missingRigidBody = (hasCollider2D && component.GetComponent<Rigidbody2D>() == null) || (hasCollider3D && component.GetComponent<Rigidbody>() == null);
+			if (missingRigidBody) {
+				using (new SpineInspectorUtility.BoxScope()) {
+					EditorGUILayout.HelpBox("Collider detected. Unity recommends adding a Rigidbody to the parent Transforms of any colliders that are intended to be dynamically repositioned and rotated.", MessageType.Warning);
+					var rbType = hasCollider2D ? typeof(Rigidbody2D) : typeof(Rigidbody);
+					string rbLabel = string.Format("Add {0}", rbType.Name);
+					var rbContent = SpineInspectorUtility.TempContent(rbLabel, SpineInspectorUtility.UnityIcon(rbType), "Add a rigidbody to this GameObject to be the Physics body parent of the attached collider.");
+					if (SpineInspectorUtility.CenteredButton(rbContent)) component.gameObject.AddComponent(rbType);
+				}
+			}
+		}
+	}
+
+}

+ 0 - 0
spine-unity/Assets/spine-unity/Editor/BoneFollowerInspector.cs.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/BoneFollowerInspector.cs.meta


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI.meta


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/AtlasAsset Icon.png → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/AtlasAsset Icon.png


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/AtlasAsset Icon.png.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/AtlasAsset Icon.png.meta


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/SkeletonDataAsset Icon.png → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/SkeletonDataAsset Icon.png


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/SkeletonDataAsset Icon.png.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/SkeletonDataAsset Icon.png.meta


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-animation.png → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-animation.png


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-animation.png.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-animation.png.meta


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-animationRoot.png → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-animationRoot.png


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-animationRoot.png.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-animationRoot.png.meta


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-attachment.png → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-attachment.png


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-attachment.png.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-attachment.png.meta


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-bone.png → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-bone.png


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-bone.png.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-bone.png.meta


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-boneNib.png → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-boneNib.png


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-boneNib.png.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-boneNib.png.meta


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-boundingBox.png → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-boundingBox.png


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-boundingBox.png.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-boundingBox.png.meta


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-clipping.png → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-clipping.png


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-clipping.png.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-clipping.png.meta


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-constraintIK.png → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-constraintIK.png


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-constraintIK.png.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-constraintIK.png.meta


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-constraintNib.png → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-constraintNib.png


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-constraintNib.png.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-constraintNib.png.meta


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-constraintPath.png → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-constraintPath.png


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-constraintPath.png.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-constraintPath.png.meta


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-constraintTransform.png → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-constraintTransform.png


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-constraintTransform.png.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-constraintTransform.png.meta


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-constraints.png → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-constraints.png


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-constraints.png.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-constraints.png.meta


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-event.png → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-event.png


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-event.png.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-event.png.meta


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-hingeChain.png → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-hingeChain.png


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-hingeChain.png.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-hingeChain.png.meta


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-image.png → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-image.png


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-image.png.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-image.png.meta


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-mesh.png → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-mesh.png


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-mesh.png.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-mesh.png.meta


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-null.png → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-null.png


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-null.png.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-null.png.meta


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-path.png → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-path.png


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-path.png.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-path.png.meta


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-point.png → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-point.png


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-point.png.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-point.png.meta


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-poseBones.png → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-poseBones.png


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-poseBones.png.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-poseBones.png.meta


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-skeleton.png → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-skeleton.png


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-skeleton.png.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-skeleton.png.meta


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-skeletonUtility.png → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-skeletonUtility.png


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-skeletonUtility.png.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-skeletonUtility.png.meta


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-skin.png → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-skin.png


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-skin.png.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-skin.png.meta


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-skinPlaceholder.png → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-skinPlaceholder.png


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-skinPlaceholder.png.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-skinPlaceholder.png.meta


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-skinsRoot.png → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-skinsRoot.png


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-skinsRoot.png.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-skinsRoot.png.meta


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-slot.png → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-slot.png


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-slot.png.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-slot.png.meta


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-slotRoot.png → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-slotRoot.png


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-slotRoot.png.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-slotRoot.png.meta


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-spine.png → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-spine.png


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-spine.png.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-spine.png.meta


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-subMeshRenderer.png → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-subMeshRenderer.png


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-subMeshRenderer.png.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-subMeshRenderer.png.meta


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-warning.png → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-warning.png


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-warning.png.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-warning.png.meta


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-weights.png → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-weights.png


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/GUI/icon-weights.png.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/GUI/icon-weights.png.meta


+ 84 - 84
spine-unity/Assets/spine-unity/Editor/Menus.cs → spine-unity/Assets/Spine/Editor/spine-unity/Editor/Menus.cs

@@ -1,84 +1,84 @@
-/******************************************************************************
- * Spine Runtimes Software License v2.5
- *
- * Copyright (c) 2013-2016, Esoteric Software
- * All rights reserved.
- *
- * You are granted a perpetual, non-exclusive, non-sublicensable, and
- * non-transferable license to use, install, execute, and perform the Spine
- * Runtimes software and derivative works solely for personal or internal
- * use. Without the written permission of Esoteric Software (see Section 2 of
- * the Spine Software License Agreement), you may not (a) modify, translate,
- * adapt, or develop new applications using the Spine Runtimes or otherwise
- * create derivative works or improvements of the Spine Runtimes or (b) remove,
- * delete, alter, or obscure any trademarks or any copyright, trademark, patent,
- * or other intellectual property or proprietary rights notices on or in the
- * Software, including any copy thereof. Redistributions in binary or source
- * form must include this license and terms.
- *
- * THIS SOFTWARE IS PROVIDED BY ESOTERIC SOFTWARE "AS IS" AND ANY EXPRESS OR
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
- * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
- * EVENT SHALL ESOTERIC SOFTWARE BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES, BUSINESS INTERRUPTION, OR LOSS OF
- * USE, DATA, OR PROFITS) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
- * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
- * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
- * POSSIBILITY OF SUCH DAMAGE.
- *****************************************************************************/
-
-using System;
-using System.IO;
-using UnityEditor;
-using UnityEngine;
-
-namespace Spine.Unity.Editor {
-	public static class Menus {
-		[MenuItem("Assets/Create/Spine/Atlas Asset")]
-		static public void CreateAtlas () {
-			CreateAsset<AtlasAsset>("New Atlas");
-		}
-
-		[MenuItem("Assets/Create/Spine/SkeletonData Asset")]
-		static public void CreateSkeletonData () {
-			CreateAsset<SkeletonDataAsset>("New SkeletonData");
-		}
-
-		static void CreateAsset<T> (String name) where T : ScriptableObject {
-			var dir = "Assets/";
-			var selected = Selection.activeObject;
-			if (selected != null) {
-				var assetDir = AssetDatabase.GetAssetPath(selected.GetInstanceID());
-				if (assetDir.Length > 0 && Directory.Exists(assetDir))
-					dir = assetDir + "/";
-			}
-			ScriptableObject asset = ScriptableObject.CreateInstance<T>();
-			AssetDatabase.CreateAsset(asset, dir + name + ".asset");
-			AssetDatabase.SaveAssets();
-			EditorUtility.FocusProjectWindow();
-			Selection.activeObject = asset;
-		}
-
-		[MenuItem("GameObject/Spine/SkeletonRenderer", false, 10)]
-		static public void CreateSkeletonRendererGameObject () {
-			CreateSpineGameObject<SkeletonRenderer>("New SkeletonRenderer");
-		}
-
-		[MenuItem("GameObject/Spine/SkeletonAnimation", false, 10)]
-		static public void CreateSkeletonAnimationGameObject () {
-			CreateSpineGameObject<SkeletonAnimation>("New SkeletonAnimation");
-		}
-
-		static void CreateSpineGameObject<T> (string name) where T : MonoBehaviour {
-			var parentGameObject = Selection.activeObject as GameObject;
-			var parentTransform = parentGameObject == null ? null : parentGameObject.transform;
-
-			var gameObject = new GameObject(name, typeof(T));
-			gameObject.transform.SetParent(parentTransform, false);
-			EditorUtility.FocusProjectWindow();
-			Selection.activeObject = gameObject;
-			EditorGUIUtility.PingObject(Selection.activeObject);
-		}
-	}
-}
+/******************************************************************************
+ * Spine Runtimes Software License v2.5
+ *
+ * Copyright (c) 2013-2016, Esoteric Software
+ * All rights reserved.
+ *
+ * You are granted a perpetual, non-exclusive, non-sublicensable, and
+ * non-transferable license to use, install, execute, and perform the Spine
+ * Runtimes software and derivative works solely for personal or internal
+ * use. Without the written permission of Esoteric Software (see Section 2 of
+ * the Spine Software License Agreement), you may not (a) modify, translate,
+ * adapt, or develop new applications using the Spine Runtimes or otherwise
+ * create derivative works or improvements of the Spine Runtimes or (b) remove,
+ * delete, alter, or obscure any trademarks or any copyright, trademark, patent,
+ * or other intellectual property or proprietary rights notices on or in the
+ * Software, including any copy thereof. Redistributions in binary or source
+ * form must include this license and terms.
+ *
+ * THIS SOFTWARE IS PROVIDED BY ESOTERIC SOFTWARE "AS IS" AND ANY EXPRESS OR
+ * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+ * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
+ * EVENT SHALL ESOTERIC SOFTWARE BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+ * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES, BUSINESS INTERRUPTION, OR LOSS OF
+ * USE, DATA, OR PROFITS) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
+ * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+ * POSSIBILITY OF SUCH DAMAGE.
+ *****************************************************************************/
+
+using System;
+using System.IO;
+using UnityEditor;
+using UnityEngine;
+
+namespace Spine.Unity.Editor {
+	public static class Menus {
+		[MenuItem("Assets/Create/Spine/Atlas Asset")]
+		static public void CreateAtlas () {
+			CreateAsset<AtlasAsset>("New Atlas");
+		}
+
+		[MenuItem("Assets/Create/Spine/SkeletonData Asset")]
+		static public void CreateSkeletonData () {
+			CreateAsset<SkeletonDataAsset>("New SkeletonData");
+		}
+
+		static void CreateAsset<T> (String name) where T : ScriptableObject {
+			var dir = "Assets/";
+			var selected = Selection.activeObject;
+			if (selected != null) {
+				var assetDir = AssetDatabase.GetAssetPath(selected.GetInstanceID());
+				if (assetDir.Length > 0 && Directory.Exists(assetDir))
+					dir = assetDir + "/";
+			}
+			ScriptableObject asset = ScriptableObject.CreateInstance<T>();
+			AssetDatabase.CreateAsset(asset, dir + name + ".asset");
+			AssetDatabase.SaveAssets();
+			EditorUtility.FocusProjectWindow();
+			Selection.activeObject = asset;
+		}
+
+		[MenuItem("GameObject/Spine/SkeletonRenderer", false, 10)]
+		static public void CreateSkeletonRendererGameObject () {
+			CreateSpineGameObject<SkeletonRenderer>("New SkeletonRenderer");
+		}
+
+		[MenuItem("GameObject/Spine/SkeletonAnimation", false, 10)]
+		static public void CreateSkeletonAnimationGameObject () {
+			CreateSpineGameObject<SkeletonAnimation>("New SkeletonAnimation");
+		}
+
+		static void CreateSpineGameObject<T> (string name) where T : MonoBehaviour {
+			var parentGameObject = Selection.activeObject as GameObject;
+			var parentTransform = parentGameObject == null ? null : parentGameObject.transform;
+
+			var gameObject = new GameObject(name, typeof(T));
+			gameObject.transform.SetParent(parentTransform, false);
+			EditorUtility.FocusProjectWindow();
+			Selection.activeObject = gameObject;
+			EditorGUIUtility.PingObject(Selection.activeObject);
+		}
+	}
+}

+ 0 - 0
spine-unity/Assets/spine-unity/Editor/Menus.cs.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/Menus.cs.meta


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/PointFollowerEditor.cs → spine-unity/Assets/Spine/Editor/spine-unity/Editor/PointFollowerEditor.cs


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/PointFollowerEditor.cs.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/PointFollowerEditor.cs.meta


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/Resources.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/Resources.meta


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/Resources/SpineAssetDatabaseMarker.txt → spine-unity/Assets/Spine/Editor/spine-unity/Editor/Resources/SpineAssetDatabaseMarker.txt


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/Resources/SpineAssetDatabaseMarker.txt.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/Resources/SpineAssetDatabaseMarker.txt.meta


+ 143 - 143
spine-unity/Assets/spine-unity/Editor/SkeletonAnimationInspector.cs → spine-unity/Assets/Spine/Editor/spine-unity/Editor/SkeletonAnimationInspector.cs

@@ -1,143 +1,143 @@
-/******************************************************************************
- * Spine Runtimes Software License v2.5
- *
- * Copyright (c) 2013-2016, Esoteric Software
- * All rights reserved.
- *
- * You are granted a perpetual, non-exclusive, non-sublicensable, and
- * non-transferable license to use, install, execute, and perform the Spine
- * Runtimes software and derivative works solely for personal or internal
- * use. Without the written permission of Esoteric Software (see Section 2 of
- * the Spine Software License Agreement), you may not (a) modify, translate,
- * adapt, or develop new applications using the Spine Runtimes or otherwise
- * create derivative works or improvements of the Spine Runtimes or (b) remove,
- * delete, alter, or obscure any trademarks or any copyright, trademark, patent,
- * or other intellectual property or proprietary rights notices on or in the
- * Software, including any copy thereof. Redistributions in binary or source
- * form must include this license and terms.
- *
- * THIS SOFTWARE IS PROVIDED BY ESOTERIC SOFTWARE "AS IS" AND ANY EXPRESS OR
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
- * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
- * EVENT SHALL ESOTERIC SOFTWARE BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES, BUSINESS INTERRUPTION, OR LOSS OF
- * USE, DATA, OR PROFITS) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
- * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
- * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
- * POSSIBILITY OF SUCH DAMAGE.
- *****************************************************************************/
-
-using UnityEditor;
-using UnityEngine;
-using Spine;
-
-namespace Spine.Unity.Editor {
-	
-	[CustomEditor(typeof(SkeletonAnimation))]
-	[CanEditMultipleObjects]
-	public class SkeletonAnimationInspector : SkeletonRendererInspector {
-		protected SerializedProperty animationName, loop, timeScale, autoReset;
-		protected bool wasAnimationNameChanged;
-		protected bool requireRepaint;
-		readonly GUIContent LoopLabel = new GUIContent("Loop", "Whether or not .AnimationName should loop. This only applies to the initial animation specified in the inspector, or any subsequent Animations played through .AnimationName. Animations set through state.SetAnimation are unaffected.");
-		readonly GUIContent TimeScaleLabel = new GUIContent("Time Scale", "The rate at which animations progress over time. 1 means normal speed. 0.5 means 50% speed.");
-
-		protected override void OnEnable () {
-			base.OnEnable();
-			animationName = serializedObject.FindProperty("_animationName");
-			loop = serializedObject.FindProperty("loop");
-			timeScale = serializedObject.FindProperty("timeScale");
-		}
-
-		protected override void DrawInspectorGUI (bool multi) {
-			base.DrawInspectorGUI(multi);
-			if (!TargetIsValid) return;
-			bool sameData = SpineInspectorUtility.TargetsUseSameData(serializedObject);
-
-			if (multi) {
-				foreach (var o in targets)		
-					TrySetAnimation(o, multi);
-				
-				EditorGUILayout.Space();
-				if (!sameData) {
-					#if UNITY_5_3_OR_NEWER
-					EditorGUILayout.DelayedTextField(animationName);
-					#else
-					animationName.stringValue = EditorGUILayout.TextField(animationName.displayName, animationName.stringValue);
-					#endif
-				} else {
-					EditorGUI.BeginChangeCheck();
-					EditorGUILayout.PropertyField(animationName);
-					wasAnimationNameChanged |= EditorGUI.EndChangeCheck(); // Value used in the next update.
-				}
-				EditorGUILayout.PropertyField(loop);
-				EditorGUILayout.PropertyField(timeScale);
-				foreach (var o in targets) {
-					var component = o as SkeletonAnimation;
-					component.timeScale = Mathf.Max(component.timeScale, 0);
-				}
-			} else {
-				TrySetAnimation(target, multi);
-
-				EditorGUILayout.Space();
-				EditorGUI.BeginChangeCheck();
-				EditorGUILayout.PropertyField(animationName);
-				wasAnimationNameChanged |= EditorGUI.EndChangeCheck(); // Value used in the next update.
-				EditorGUILayout.PropertyField(loop, LoopLabel);
-				EditorGUILayout.PropertyField(timeScale, TimeScaleLabel);
-				var component = (SkeletonAnimation)target;
-				component.timeScale = Mathf.Max(component.timeScale, 0);
-				EditorGUILayout.Space();
-			}
-
-			if (!isInspectingPrefab) {
-				if (requireRepaint) {
-					SceneView.RepaintAll();
-					requireRepaint = false;
-				}
-			}
-		}
-
-		protected void TrySetAnimation (Object o, bool multi) {
-			var skeletonAnimation = o as SkeletonAnimation;
-			if (skeletonAnimation == null) return;
-			if (!skeletonAnimation.valid)
-				return;
-
-			if (!isInspectingPrefab) {
-				if (wasAnimationNameChanged) {
-					if (!Application.isPlaying) {
-						if (skeletonAnimation.state != null) skeletonAnimation.state.ClearTrack(0);
-						skeletonAnimation.skeleton.SetToSetupPose();
-					}
-
-					Spine.Animation animationToUse = skeletonAnimation.skeleton.Data.FindAnimation(animationName.stringValue);
-
-					if (!Application.isPlaying) {
-						if (animationToUse != null) animationToUse.PoseSkeleton(skeletonAnimation.Skeleton, 0f);
-						skeletonAnimation.Update(0);
-						skeletonAnimation.LateUpdate();
-						requireRepaint = true;
-					} else {
-						if (animationToUse != null)
-							skeletonAnimation.state.SetAnimation(0, animationToUse, loop.boolValue);
-						else
-							skeletonAnimation.state.ClearTrack(0);
-					}
-
-					wasAnimationNameChanged = false;
-				}
-
-				// Reflect animationName serialized property in the inspector even if SetAnimation API was used.
-				if (!multi && Application.isPlaying) {
-					TrackEntry current = skeletonAnimation.state.GetCurrent(0);
-					if (current != null) {
-						if (skeletonAnimation.AnimationName != animationName.stringValue)
-							animationName.stringValue = current.Animation.Name;
-					}
-				}
-			}
-		}
-	}
-}
+/******************************************************************************
+ * Spine Runtimes Software License v2.5
+ *
+ * Copyright (c) 2013-2016, Esoteric Software
+ * All rights reserved.
+ *
+ * You are granted a perpetual, non-exclusive, non-sublicensable, and
+ * non-transferable license to use, install, execute, and perform the Spine
+ * Runtimes software and derivative works solely for personal or internal
+ * use. Without the written permission of Esoteric Software (see Section 2 of
+ * the Spine Software License Agreement), you may not (a) modify, translate,
+ * adapt, or develop new applications using the Spine Runtimes or otherwise
+ * create derivative works or improvements of the Spine Runtimes or (b) remove,
+ * delete, alter, or obscure any trademarks or any copyright, trademark, patent,
+ * or other intellectual property or proprietary rights notices on or in the
+ * Software, including any copy thereof. Redistributions in binary or source
+ * form must include this license and terms.
+ *
+ * THIS SOFTWARE IS PROVIDED BY ESOTERIC SOFTWARE "AS IS" AND ANY EXPRESS OR
+ * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+ * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
+ * EVENT SHALL ESOTERIC SOFTWARE BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+ * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES, BUSINESS INTERRUPTION, OR LOSS OF
+ * USE, DATA, OR PROFITS) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
+ * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+ * POSSIBILITY OF SUCH DAMAGE.
+ *****************************************************************************/
+
+using UnityEditor;
+using UnityEngine;
+using Spine;
+
+namespace Spine.Unity.Editor {
+	
+	[CustomEditor(typeof(SkeletonAnimation))]
+	[CanEditMultipleObjects]
+	public class SkeletonAnimationInspector : SkeletonRendererInspector {
+		protected SerializedProperty animationName, loop, timeScale, autoReset;
+		protected bool wasAnimationNameChanged;
+		protected bool requireRepaint;
+		readonly GUIContent LoopLabel = new GUIContent("Loop", "Whether or not .AnimationName should loop. This only applies to the initial animation specified in the inspector, or any subsequent Animations played through .AnimationName. Animations set through state.SetAnimation are unaffected.");
+		readonly GUIContent TimeScaleLabel = new GUIContent("Time Scale", "The rate at which animations progress over time. 1 means normal speed. 0.5 means 50% speed.");
+
+		protected override void OnEnable () {
+			base.OnEnable();
+			animationName = serializedObject.FindProperty("_animationName");
+			loop = serializedObject.FindProperty("loop");
+			timeScale = serializedObject.FindProperty("timeScale");
+		}
+
+		protected override void DrawInspectorGUI (bool multi) {
+			base.DrawInspectorGUI(multi);
+			if (!TargetIsValid) return;
+			bool sameData = SpineInspectorUtility.TargetsUseSameData(serializedObject);
+
+			if (multi) {
+				foreach (var o in targets)		
+					TrySetAnimation(o, multi);
+				
+				EditorGUILayout.Space();
+				if (!sameData) {
+					#if UNITY_5_3_OR_NEWER
+					EditorGUILayout.DelayedTextField(animationName);
+					#else
+					animationName.stringValue = EditorGUILayout.TextField(animationName.displayName, animationName.stringValue);
+					#endif
+				} else {
+					EditorGUI.BeginChangeCheck();
+					EditorGUILayout.PropertyField(animationName);
+					wasAnimationNameChanged |= EditorGUI.EndChangeCheck(); // Value used in the next update.
+				}
+				EditorGUILayout.PropertyField(loop);
+				EditorGUILayout.PropertyField(timeScale);
+				foreach (var o in targets) {
+					var component = o as SkeletonAnimation;
+					component.timeScale = Mathf.Max(component.timeScale, 0);
+				}
+			} else {
+				TrySetAnimation(target, multi);
+
+				EditorGUILayout.Space();
+				EditorGUI.BeginChangeCheck();
+				EditorGUILayout.PropertyField(animationName);
+				wasAnimationNameChanged |= EditorGUI.EndChangeCheck(); // Value used in the next update.
+				EditorGUILayout.PropertyField(loop, LoopLabel);
+				EditorGUILayout.PropertyField(timeScale, TimeScaleLabel);
+				var component = (SkeletonAnimation)target;
+				component.timeScale = Mathf.Max(component.timeScale, 0);
+				EditorGUILayout.Space();
+			}
+
+			if (!isInspectingPrefab) {
+				if (requireRepaint) {
+					SceneView.RepaintAll();
+					requireRepaint = false;
+				}
+			}
+		}
+
+		protected void TrySetAnimation (Object o, bool multi) {
+			var skeletonAnimation = o as SkeletonAnimation;
+			if (skeletonAnimation == null) return;
+			if (!skeletonAnimation.valid)
+				return;
+
+			if (!isInspectingPrefab) {
+				if (wasAnimationNameChanged) {
+					if (!Application.isPlaying) {
+						if (skeletonAnimation.state != null) skeletonAnimation.state.ClearTrack(0);
+						skeletonAnimation.skeleton.SetToSetupPose();
+					}
+
+					Spine.Animation animationToUse = skeletonAnimation.skeleton.Data.FindAnimation(animationName.stringValue);
+
+					if (!Application.isPlaying) {
+						if (animationToUse != null) animationToUse.PoseSkeleton(skeletonAnimation.Skeleton, 0f);
+						skeletonAnimation.Update(0);
+						skeletonAnimation.LateUpdate();
+						requireRepaint = true;
+					} else {
+						if (animationToUse != null)
+							skeletonAnimation.state.SetAnimation(0, animationToUse, loop.boolValue);
+						else
+							skeletonAnimation.state.ClearTrack(0);
+					}
+
+					wasAnimationNameChanged = false;
+				}
+
+				// Reflect animationName serialized property in the inspector even if SetAnimation API was used.
+				if (!multi && Application.isPlaying) {
+					TrackEntry current = skeletonAnimation.state.GetCurrent(0);
+					if (current != null) {
+						if (skeletonAnimation.AnimationName != animationName.stringValue)
+							animationName.stringValue = current.Animation.Name;
+					}
+				}
+			}
+		}
+	}
+}

+ 0 - 0
spine-unity/Assets/spine-unity/Editor/SkeletonAnimationInspector.cs.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/SkeletonAnimationInspector.cs.meta


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/SkeletonAnimatorInspector.cs → spine-unity/Assets/Spine/Editor/spine-unity/Editor/SkeletonAnimatorInspector.cs


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/SkeletonAnimatorInspector.cs.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/SkeletonAnimatorInspector.cs.meta


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/SkeletonBaker.cs → spine-unity/Assets/Spine/Editor/spine-unity/Editor/SkeletonBaker.cs


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/SkeletonBaker.cs.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/SkeletonBaker.cs.meta


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/SkeletonBakingWindow.cs → spine-unity/Assets/Spine/Editor/spine-unity/Editor/SkeletonBakingWindow.cs


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/SkeletonBakingWindow.cs.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/SkeletonBakingWindow.cs.meta


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/SkeletonDataAssetInspector.cs → spine-unity/Assets/Spine/Editor/spine-unity/Editor/SkeletonDataAssetInspector.cs


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/SkeletonDataAssetInspector.cs.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/SkeletonDataAssetInspector.cs.meta


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/SkeletonDebugWindow.cs → spine-unity/Assets/Spine/Editor/spine-unity/Editor/SkeletonDebugWindow.cs


+ 0 - 0
spine-unity/Assets/spine-unity/Editor/SkeletonDebugWindow.cs.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/SkeletonDebugWindow.cs.meta


+ 398 - 398
spine-unity/Assets/spine-unity/Editor/SkeletonRendererInspector.cs → spine-unity/Assets/Spine/Editor/spine-unity/Editor/SkeletonRendererInspector.cs

@@ -1,398 +1,398 @@
-/******************************************************************************
- * Spine Runtimes Software License v2.5
- *
- * Copyright (c) 2013-2016, Esoteric Software
- * All rights reserved.
- *
- * You are granted a perpetual, non-exclusive, non-sublicensable, and
- * non-transferable license to use, install, execute, and perform the Spine
- * Runtimes software and derivative works solely for personal or internal
- * use. Without the written permission of Esoteric Software (see Section 2 of
- * the Spine Software License Agreement), you may not (a) modify, translate,
- * adapt, or develop new applications using the Spine Runtimes or otherwise
- * create derivative works or improvements of the Spine Runtimes or (b) remove,
- * delete, alter, or obscure any trademarks or any copyright, trademark, patent,
- * or other intellectual property or proprietary rights notices on or in the
- * Software, including any copy thereof. Redistributions in binary or source
- * form must include this license and terms.
- *
- * THIS SOFTWARE IS PROVIDED BY ESOTERIC SOFTWARE "AS IS" AND ANY EXPRESS OR
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
- * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
- * EVENT SHALL ESOTERIC SOFTWARE BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES, BUSINESS INTERRUPTION, OR LOSS OF
- * USE, DATA, OR PROFITS) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
- * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
- * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
- * POSSIBILITY OF SUCH DAMAGE.
- *****************************************************************************/
-
-#define NO_PREFAB_MESH
-
-using UnityEditor;
-using System.Collections.Generic;
-using UnityEngine;
-
-namespace Spine.Unity.Editor {
-	using Event = UnityEngine.Event;
-	using Icons = SpineEditorUtilities.Icons;
-
-	[CustomEditor(typeof(SkeletonRenderer))]
-	[CanEditMultipleObjects]
-	public class SkeletonRendererInspector : UnityEditor.Editor {
-		public static bool advancedFoldout;
-
-		protected SerializedProperty skeletonDataAsset, initialSkinName;
-		protected SerializedProperty initialFlipX, initialFlipY;
-		protected SerializedProperty singleSubmesh, separatorSlotNames, clearStateOnDisable, immutableTriangles;
-		protected SerializedProperty normals, tangents, meshes, zSpacing, pmaVertexColors, tintBlack; // MeshGenerator settings
-		protected SpineInspectorUtility.SerializedSortingProperties sortingProperties;
-		protected bool isInspectingPrefab;
-
-		protected GUIContent SkeletonDataAssetLabel, SkeletonUtilityButtonContent;
-		protected GUIContent PMAVertexColorsLabel, ClearStateOnDisableLabel, ZSpacingLabel, MeshesLabel, ImmubleTrianglesLabel, TintBlackLabel, SingleSubmeshLabel;
-		protected GUIContent NormalsLabel, TangentsLabel;
-		const string ReloadButtonLabel = "Reload";
-
-		protected bool TargetIsValid {
-			get {
-				if (serializedObject.isEditingMultipleObjects) {
-					foreach (var o in targets) {
-						var component = (SkeletonRenderer)o;
-						if (!component.valid)
-							return false;
-					}
-					return true;
-				} else {
-					var component = (SkeletonRenderer)target;
-					return component.valid;
-				}
-			}
-		}
-
-		protected virtual void OnEnable () {
-			isInspectingPrefab = (PrefabUtility.GetPrefabType(target) == PrefabType.Prefab);
-			
-			SpineEditorUtilities.ConfirmInitialization();
-
-			// Labels
-			SkeletonDataAssetLabel = new GUIContent("SkeletonData Asset", Icons.spine);
-			SkeletonUtilityButtonContent = new GUIContent("Add Skeleton Utility", Icons.skeletonUtility);
-			MeshesLabel = new GUIContent("Render MeshAttachments", "Disable to optimize rendering for skeletons that don't use Mesh Attachments");
-			ImmubleTrianglesLabel = new GUIContent("Immutable Triangles", "Enable to optimize rendering for skeletons that never change attachment visbility");
-			PMAVertexColorsLabel = new GUIContent("PMA Vertex Colors", "Use this if you are using the default Spine/Skeleton shader or any premultiply-alpha shader.");
-			ClearStateOnDisableLabel = new GUIContent("Clear State On Disable", "Use this if you are pooling or enabling/disabling your Spine GameObject.");
-			ZSpacingLabel = new GUIContent("Z Spacing", "A value other than 0 adds a space between each rendered attachment to prevent Z Fighting when using shaders that read or write to the depth buffer. Large values may cause unwanted parallax and spaces depending on camera setup.");
-			NormalsLabel = new GUIContent("Add Normals", "Use this if your shader requires vertex normals. A more efficient solution for 2D setups is to modify the shader to assume a single normal value for the whole mesh.");
-			TangentsLabel = new GUIContent("Solve Tangents", "Calculates the tangents per frame. Use this if you are using lit shaders (usually with normal maps) that require vertex tangents.");
-			TintBlackLabel = new GUIContent("Tint Black (!)", "Adds black tint vertex data to the mesh as UV2 and UV3. Black tinting requires that the shader interpret UV2 and UV3 as black tint colors for this effect to work. You may also use the default [Spine/Skeleton Tint Black] shader.\n\nIf you only need to tint the whole skeleton and not individual parts, the [Spine/Skeleton Tint] shader is recommended for better efficiency and changing/animating the _Black material property via MaterialPropertyBlock.");
-			SingleSubmeshLabel = new GUIContent("Use Single Submesh", "Simplifies submesh determination by assuming you are only using one Material and need only one submesh. This is will disable render separation and custom slot materials.");
-
-			var so = this.serializedObject;
-			skeletonDataAsset = so.FindProperty("skeletonDataAsset");
-			initialSkinName = so.FindProperty("initialSkinName");
-			initialFlipX = so.FindProperty("initialFlipX");
-			initialFlipY = so.FindProperty("initialFlipY");
-			normals = so.FindProperty("addNormals");
-			tangents = so.FindProperty("calculateTangents");
-			meshes = so.FindProperty("renderMeshes");
-			immutableTriangles = so.FindProperty("immutableTriangles");
-			pmaVertexColors = so.FindProperty("pmaVertexColors");
-			clearStateOnDisable = so.FindProperty("clearStateOnDisable");
-			tintBlack = so.FindProperty("tintBlack");
-			singleSubmesh = so.FindProperty("singleSubmesh");
-
-			separatorSlotNames = so.FindProperty("separatorSlotNames");
-			separatorSlotNames.isExpanded = true;
-
-			zSpacing = so.FindProperty("zSpacing");
-
-			SerializedObject rso = SpineInspectorUtility.GetRenderersSerializedObject(serializedObject);
-			sortingProperties = new SpineInspectorUtility.SerializedSortingProperties(rso);
-		}
-
-		public static void ReapplySeparatorSlotNames (SkeletonRenderer skeletonRenderer) {
-			if (!skeletonRenderer.valid) return;
-
-			var separatorSlots = skeletonRenderer.separatorSlots;
-			var separatorSlotNames = skeletonRenderer.separatorSlotNames;
-			var skeleton = skeletonRenderer.skeleton;
-
-			separatorSlots.Clear();
-			for (int i = 0, n = separatorSlotNames.Length; i < n; i++) {
-				var slot = skeleton.FindSlot(separatorSlotNames[i]);
-				if (slot != null) {
-					separatorSlots.Add(slot);
-				} else {
-					Debug.LogWarning(separatorSlotNames[i] + " is not a slot in " + skeletonRenderer.skeletonDataAsset.skeletonJSON.name);				
-				}
-			}
-		}
-
-		GUIContent[] skins;
-		ExposedList<Skin> loadedSkinList;
-
-		protected virtual void DrawInspectorGUI (bool multi) {
-			bool valid = TargetIsValid;
-			var reloadWidth = GUILayout.Width(GUI.skin.label.CalcSize(new GUIContent(ReloadButtonLabel)).x + 20);
-			var reloadButtonStyle = EditorStyles.miniButtonRight;
-
-			if (multi) {
-				using (new EditorGUILayout.HorizontalScope(EditorStyles.helpBox)) {
-					SpineInspectorUtility.PropertyFieldFitLabel(skeletonDataAsset, SkeletonDataAssetLabel);
-					if (GUILayout.Button(ReloadButtonLabel, reloadButtonStyle, reloadWidth)) {
-						foreach (var c in targets) {
-							var component = c as SkeletonRenderer;
-							if (component.skeletonDataAsset != null) {
-								foreach (AtlasAsset aa in component.skeletonDataAsset.atlasAssets) {
-									if (aa != null)
-										aa.Clear();
-								}
-								component.skeletonDataAsset.Clear();
-							}
-							component.Initialize(true);
-						}
-					}
-				}
-
-				foreach (var c in targets) {
-					var component = c as SkeletonRenderer;
-					if (!component.valid) {
-						if (Event.current.type == EventType.Layout) {
-							component.Initialize(true);
-							component.LateUpdate();
-						}
-						if (!component.valid)
-							continue;
-					}
-
-					#if NO_PREFAB_MESH
-					if (isInspectingPrefab) {
-						MeshFilter meshFilter = component.GetComponent<MeshFilter>();
-						if (meshFilter != null && meshFilter.sharedMesh != null)
-							meshFilter.sharedMesh = null;
-					}
-					#endif
-				}
-					
-				if (valid)
-					EditorGUILayout.PropertyField(initialSkinName);					
-
-			} else {
-				var component = (SkeletonRenderer)target;
-
-				if (!component.valid && Event.current.type == EventType.Layout) {
-					component.Initialize(true);
-					component.LateUpdate();
-				}
-
-				using (new EditorGUILayout.HorizontalScope(EditorStyles.helpBox)) {
-					SpineInspectorUtility.PropertyFieldFitLabel(skeletonDataAsset, SkeletonDataAssetLabel);
-					if (component.valid) {
-						if (GUILayout.Button(ReloadButtonLabel, reloadButtonStyle, reloadWidth)) {
-							if (component.skeletonDataAsset != null) {
-								foreach (AtlasAsset aa in component.skeletonDataAsset.atlasAssets) {
-									if (aa != null)
-										aa.Clear();
-								}
-								component.skeletonDataAsset.Clear();
-							}
-							component.Initialize(true);
-						}
-					}
-				}
-
-				if (component.skeletonDataAsset == null) {
-					EditorGUILayout.HelpBox("Skeleton Data Asset required", MessageType.Warning);
-					return;
-				}
-
-				#if NO_PREFAB_MESH
-				if (isInspectingPrefab) {
-					MeshFilter meshFilter = component.GetComponent<MeshFilter>();
-					if (meshFilter != null && meshFilter.sharedMesh != null)
-						meshFilter.sharedMesh = null;
-				}
-				#endif
-
-				// Initial skin name.
-				if (component.valid) {
-					var skeletonDataSkins = component.skeleton.Data.Skins;
-					int skinCount = skeletonDataSkins.Count;
-					if (loadedSkinList != skeletonDataSkins) {
-						skins = new GUIContent[skinCount];
-						loadedSkinList = skeletonDataSkins;
-						for (int i = 0; i < skins.Length; i++) {
-							string skinNameString = skeletonDataSkins.Items[i].Name;
-							skins[i] = new GUIContent(skinNameString, Icons.skin);
-						}
-					}
-					
-					int skinIndex = 0;
-					for (int i = 0; i < skins.Length; i++) {
-						string skinNameString = skeletonDataSkins.Items[i].Name;
-						if (skinNameString == initialSkinName.stringValue)
-							skinIndex = i;
-					}
-
-					skinIndex = EditorGUILayout.Popup(SpineInspectorUtility.TempContent("Initial Skin"), skinIndex, skins);
-					if (skins.Length > 0) // Support attachmentless/skinless SkeletonData.
-						initialSkinName.stringValue = skins[skinIndex].text;
-				}
-			}
-
-			EditorGUILayout.Space();
-
-			// Sorting Layers
-			SpineInspectorUtility.SortingPropertyFields(sortingProperties, applyModifiedProperties: true);
-
-			if (!TargetIsValid) return;
-			
-			// More Render Options...
-			using (new SpineInspectorUtility.BoxScope()) {
-				EditorGUI.BeginChangeCheck();
-
-				EditorGUILayout.BeginHorizontal(GUILayout.Height(EditorGUIUtility.singleLineHeight + 5));
-				advancedFoldout = EditorGUILayout.Foldout(advancedFoldout, "Advanced");
-				if (advancedFoldout) {
-					EditorGUILayout.Space();
-					if (GUILayout.Button("Debug", EditorStyles.miniButton, GUILayout.Width(65f)))
-						SkeletonDebugWindow.Init();
-				} else {
-					EditorGUILayout.Space();
-				}
-				EditorGUILayout.EndHorizontal();
-
-				if (advancedFoldout) {
-					
-					using (new SpineInspectorUtility.IndentScope()) {
-						using (new EditorGUILayout.HorizontalScope()) {
-							initialFlipX.boolValue = EditorGUILayout.ToggleLeft(initialFlipX.displayName, initialFlipX.boolValue, GUILayout.Width(120f));
-							initialFlipY.boolValue = EditorGUILayout.ToggleLeft(initialFlipY.displayName, initialFlipY.boolValue, GUILayout.Width(120f));
-							EditorGUILayout.Space();
-						}
-
-						EditorGUILayout.Space();
-						EditorGUILayout.LabelField("Renderer Settings", EditorStyles.boldLabel);
-						using (new SpineInspectorUtility.LabelWidthScope()) {
-							// Optimization options
-							if (singleSubmesh != null) EditorGUILayout.PropertyField(singleSubmesh, SingleSubmeshLabel);
-							//if (meshes != null) EditorGUILayout.PropertyField(meshes, MeshesLabel);
-							if (immutableTriangles != null) EditorGUILayout.PropertyField(immutableTriangles, ImmubleTrianglesLabel);
-							EditorGUILayout.PropertyField(clearStateOnDisable, ClearStateOnDisableLabel);
-							EditorGUILayout.Space();
-						}
-
-						SeparatorsField(separatorSlotNames);
-						EditorGUILayout.Space();
-
-						// Render options
-						const float MinZSpacing = -0.1f;
-						const float MaxZSpacing = 0f;
-						EditorGUILayout.Slider(zSpacing, MinZSpacing, MaxZSpacing, ZSpacingLabel);
-						EditorGUILayout.Space();
-
-						using (new SpineInspectorUtility.LabelWidthScope()) {
-							EditorGUILayout.LabelField(SpineInspectorUtility.TempContent("Vertex Data", SpineInspectorUtility.UnityIcon<MeshFilter>()), EditorStyles.boldLabel);
-							if (pmaVertexColors != null) EditorGUILayout.PropertyField(pmaVertexColors, PMAVertexColorsLabel);
-							EditorGUILayout.PropertyField(tintBlack, TintBlackLabel);
-
-							// Optional fields. May be disabled in SkeletonRenderer.
-							if (normals != null) EditorGUILayout.PropertyField(normals, NormalsLabel);
-							if (tangents != null) EditorGUILayout.PropertyField(tangents, TangentsLabel);
-						}
-
-						EditorGUILayout.Space();
-
-						if (TargetIsValid && !isInspectingPrefab) {
-							if (multi) {
-								// Support multi-edit SkeletonUtility button.
-								//	EditorGUILayout.Space();
-								//	bool addSkeletonUtility = GUILayout.Button(buttonContent, GUILayout.Height(30));
-								//	foreach (var t in targets) {
-								//		var component = t as Component;
-								//		if (addSkeletonUtility && component.GetComponent<SkeletonUtility>() == null)
-								//			component.gameObject.AddComponent<SkeletonUtility>();
-								//	}
-							} else {
-								var component = (Component)target;
-								if (component.GetComponent<SkeletonUtility>() == null) {						
-									if (SpineInspectorUtility.CenteredButton(SkeletonUtilityButtonContent, 21, true, 200f))
-										component.gameObject.AddComponent<SkeletonUtility>();
-								}
-							}
-						}
-
-						EditorGUILayout.Space();
-					}
-				}
-
-				if (EditorGUI.EndChangeCheck())
-					SceneView.RepaintAll();
-			}
-		}
-
-		public static void SeparatorsField (SerializedProperty separatorSlotNames) {
-			bool multi = separatorSlotNames.serializedObject.isEditingMultipleObjects;
-			bool hasTerminalSlot = false;
-			if (!multi) {
-				var sr = separatorSlotNames.serializedObject.targetObject as ISkeletonComponent;
-				var skeleton = sr.Skeleton;
-				int lastSlot = skeleton.Slots.Count - 1;
-				if (skeleton != null) {					
-					for (int i = 0, n = separatorSlotNames.arraySize; i < n; i++) {
-						int index = skeleton.FindSlotIndex(separatorSlotNames.GetArrayElementAtIndex(i).stringValue);
-						if (index == 0 || index == lastSlot) {
-							hasTerminalSlot = true;
-							break;
-						}
-					}
-				}
-			}
-
-			string terminalSlotWarning = hasTerminalSlot ? " (!)" : "";
-
-			using (new EditorGUILayout.VerticalScope(EditorStyles.helpBox)) {
-				const string SeparatorsDescription = "Stored names of slots where the Skeleton's render will be split into different batches. This is used by separate components that split the render into different MeshRenderers or GameObjects.";
-				if (separatorSlotNames.isExpanded) {
-					EditorGUILayout.PropertyField(separatorSlotNames, SpineInspectorUtility.TempContent(separatorSlotNames.displayName + terminalSlotWarning, Icons.slotRoot, SeparatorsDescription), true);
-					GUILayout.BeginHorizontal();
-					GUILayout.FlexibleSpace();
-					if (GUILayout.Button("+", GUILayout.MaxWidth(28f), GUILayout.MaxHeight(15f))) {
-						separatorSlotNames.arraySize++;
-					}
-					GUILayout.EndHorizontal();
-
-					EditorGUILayout.Space();
-				} else
-					EditorGUILayout.PropertyField(separatorSlotNames, new GUIContent(separatorSlotNames.displayName + string.Format("{0} [{1}]", terminalSlotWarning, separatorSlotNames.arraySize), SeparatorsDescription), true);
-			}
-		}
-
-		public void OnSceneGUI () {
-			var skeletonRenderer = (SkeletonRenderer)target;
-			var skeleton = skeletonRenderer.skeleton;
-			var transform = skeletonRenderer.transform;
-			if (skeleton == null) return;
-
-			SpineHandles.DrawBones(transform, skeleton);
-		}
-
-		override public void OnInspectorGUI () {
-			//serializedObject.Update();
-			bool multi = serializedObject.isEditingMultipleObjects;
-			DrawInspectorGUI(multi);
-			if (serializedObject.ApplyModifiedProperties() || SpineInspectorUtility.UndoRedoPerformed(Event.current)) {
-				if (!Application.isPlaying) {
-					if (multi)
-						foreach (var o in targets)
-							((SkeletonRenderer)o).Initialize(true);
-					else
-						((SkeletonRenderer)target).Initialize(true);
-				}
-			}
-		}
-
-	}
-}
+/******************************************************************************
+ * Spine Runtimes Software License v2.5
+ *
+ * Copyright (c) 2013-2016, Esoteric Software
+ * All rights reserved.
+ *
+ * You are granted a perpetual, non-exclusive, non-sublicensable, and
+ * non-transferable license to use, install, execute, and perform the Spine
+ * Runtimes software and derivative works solely for personal or internal
+ * use. Without the written permission of Esoteric Software (see Section 2 of
+ * the Spine Software License Agreement), you may not (a) modify, translate,
+ * adapt, or develop new applications using the Spine Runtimes or otherwise
+ * create derivative works or improvements of the Spine Runtimes or (b) remove,
+ * delete, alter, or obscure any trademarks or any copyright, trademark, patent,
+ * or other intellectual property or proprietary rights notices on or in the
+ * Software, including any copy thereof. Redistributions in binary or source
+ * form must include this license and terms.
+ *
+ * THIS SOFTWARE IS PROVIDED BY ESOTERIC SOFTWARE "AS IS" AND ANY EXPRESS OR
+ * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+ * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
+ * EVENT SHALL ESOTERIC SOFTWARE BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+ * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES, BUSINESS INTERRUPTION, OR LOSS OF
+ * USE, DATA, OR PROFITS) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
+ * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+ * POSSIBILITY OF SUCH DAMAGE.
+ *****************************************************************************/
+
+#define NO_PREFAB_MESH
+
+using UnityEditor;
+using System.Collections.Generic;
+using UnityEngine;
+
+namespace Spine.Unity.Editor {
+	using Event = UnityEngine.Event;
+	using Icons = SpineEditorUtilities.Icons;
+
+	[CustomEditor(typeof(SkeletonRenderer))]
+	[CanEditMultipleObjects]
+	public class SkeletonRendererInspector : UnityEditor.Editor {
+		public static bool advancedFoldout;
+
+		protected SerializedProperty skeletonDataAsset, initialSkinName;
+		protected SerializedProperty initialFlipX, initialFlipY;
+		protected SerializedProperty singleSubmesh, separatorSlotNames, clearStateOnDisable, immutableTriangles;
+		protected SerializedProperty normals, tangents, meshes, zSpacing, pmaVertexColors, tintBlack; // MeshGenerator settings
+		protected SpineInspectorUtility.SerializedSortingProperties sortingProperties;
+		protected bool isInspectingPrefab;
+
+		protected GUIContent SkeletonDataAssetLabel, SkeletonUtilityButtonContent;
+		protected GUIContent PMAVertexColorsLabel, ClearStateOnDisableLabel, ZSpacingLabel, MeshesLabel, ImmubleTrianglesLabel, TintBlackLabel, SingleSubmeshLabel;
+		protected GUIContent NormalsLabel, TangentsLabel;
+		const string ReloadButtonLabel = "Reload";
+
+		protected bool TargetIsValid {
+			get {
+				if (serializedObject.isEditingMultipleObjects) {
+					foreach (var o in targets) {
+						var component = (SkeletonRenderer)o;
+						if (!component.valid)
+							return false;
+					}
+					return true;
+				} else {
+					var component = (SkeletonRenderer)target;
+					return component.valid;
+				}
+			}
+		}
+
+		protected virtual void OnEnable () {
+			isInspectingPrefab = (PrefabUtility.GetPrefabType(target) == PrefabType.Prefab);
+			
+			SpineEditorUtilities.ConfirmInitialization();
+
+			// Labels
+			SkeletonDataAssetLabel = new GUIContent("SkeletonData Asset", Icons.spine);
+			SkeletonUtilityButtonContent = new GUIContent("Add Skeleton Utility", Icons.skeletonUtility);
+			MeshesLabel = new GUIContent("Render MeshAttachments", "Disable to optimize rendering for skeletons that don't use Mesh Attachments");
+			ImmubleTrianglesLabel = new GUIContent("Immutable Triangles", "Enable to optimize rendering for skeletons that never change attachment visbility");
+			PMAVertexColorsLabel = new GUIContent("PMA Vertex Colors", "Use this if you are using the default Spine/Skeleton shader or any premultiply-alpha shader.");
+			ClearStateOnDisableLabel = new GUIContent("Clear State On Disable", "Use this if you are pooling or enabling/disabling your Spine GameObject.");
+			ZSpacingLabel = new GUIContent("Z Spacing", "A value other than 0 adds a space between each rendered attachment to prevent Z Fighting when using shaders that read or write to the depth buffer. Large values may cause unwanted parallax and spaces depending on camera setup.");
+			NormalsLabel = new GUIContent("Add Normals", "Use this if your shader requires vertex normals. A more efficient solution for 2D setups is to modify the shader to assume a single normal value for the whole mesh.");
+			TangentsLabel = new GUIContent("Solve Tangents", "Calculates the tangents per frame. Use this if you are using lit shaders (usually with normal maps) that require vertex tangents.");
+			TintBlackLabel = new GUIContent("Tint Black (!)", "Adds black tint vertex data to the mesh as UV2 and UV3. Black tinting requires that the shader interpret UV2 and UV3 as black tint colors for this effect to work. You may also use the default [Spine/Skeleton Tint Black] shader.\n\nIf you only need to tint the whole skeleton and not individual parts, the [Spine/Skeleton Tint] shader is recommended for better efficiency and changing/animating the _Black material property via MaterialPropertyBlock.");
+			SingleSubmeshLabel = new GUIContent("Use Single Submesh", "Simplifies submesh determination by assuming you are only using one Material and need only one submesh. This is will disable render separation and custom slot materials.");
+
+			var so = this.serializedObject;
+			skeletonDataAsset = so.FindProperty("skeletonDataAsset");
+			initialSkinName = so.FindProperty("initialSkinName");
+			initialFlipX = so.FindProperty("initialFlipX");
+			initialFlipY = so.FindProperty("initialFlipY");
+			normals = so.FindProperty("addNormals");
+			tangents = so.FindProperty("calculateTangents");
+			meshes = so.FindProperty("renderMeshes");
+			immutableTriangles = so.FindProperty("immutableTriangles");
+			pmaVertexColors = so.FindProperty("pmaVertexColors");
+			clearStateOnDisable = so.FindProperty("clearStateOnDisable");
+			tintBlack = so.FindProperty("tintBlack");
+			singleSubmesh = so.FindProperty("singleSubmesh");
+
+			separatorSlotNames = so.FindProperty("separatorSlotNames");
+			separatorSlotNames.isExpanded = true;
+
+			zSpacing = so.FindProperty("zSpacing");
+
+			SerializedObject rso = SpineInspectorUtility.GetRenderersSerializedObject(serializedObject);
+			sortingProperties = new SpineInspectorUtility.SerializedSortingProperties(rso);
+		}
+
+		public static void ReapplySeparatorSlotNames (SkeletonRenderer skeletonRenderer) {
+			if (!skeletonRenderer.valid) return;
+
+			var separatorSlots = skeletonRenderer.separatorSlots;
+			var separatorSlotNames = skeletonRenderer.separatorSlotNames;
+			var skeleton = skeletonRenderer.skeleton;
+
+			separatorSlots.Clear();
+			for (int i = 0, n = separatorSlotNames.Length; i < n; i++) {
+				var slot = skeleton.FindSlot(separatorSlotNames[i]);
+				if (slot != null) {
+					separatorSlots.Add(slot);
+				} else {
+					Debug.LogWarning(separatorSlotNames[i] + " is not a slot in " + skeletonRenderer.skeletonDataAsset.skeletonJSON.name);				
+				}
+			}
+		}
+
+		GUIContent[] skins;
+		ExposedList<Skin> loadedSkinList;
+
+		protected virtual void DrawInspectorGUI (bool multi) {
+			bool valid = TargetIsValid;
+			var reloadWidth = GUILayout.Width(GUI.skin.label.CalcSize(new GUIContent(ReloadButtonLabel)).x + 20);
+			var reloadButtonStyle = EditorStyles.miniButtonRight;
+
+			if (multi) {
+				using (new EditorGUILayout.HorizontalScope(EditorStyles.helpBox)) {
+					SpineInspectorUtility.PropertyFieldFitLabel(skeletonDataAsset, SkeletonDataAssetLabel);
+					if (GUILayout.Button(ReloadButtonLabel, reloadButtonStyle, reloadWidth)) {
+						foreach (var c in targets) {
+							var component = c as SkeletonRenderer;
+							if (component.skeletonDataAsset != null) {
+								foreach (AtlasAsset aa in component.skeletonDataAsset.atlasAssets) {
+									if (aa != null)
+										aa.Clear();
+								}
+								component.skeletonDataAsset.Clear();
+							}
+							component.Initialize(true);
+						}
+					}
+				}
+
+				foreach (var c in targets) {
+					var component = c as SkeletonRenderer;
+					if (!component.valid) {
+						if (Event.current.type == EventType.Layout) {
+							component.Initialize(true);
+							component.LateUpdate();
+						}
+						if (!component.valid)
+							continue;
+					}
+
+					#if NO_PREFAB_MESH
+					if (isInspectingPrefab) {
+						MeshFilter meshFilter = component.GetComponent<MeshFilter>();
+						if (meshFilter != null && meshFilter.sharedMesh != null)
+							meshFilter.sharedMesh = null;
+					}
+					#endif
+				}
+					
+				if (valid)
+					EditorGUILayout.PropertyField(initialSkinName);					
+
+			} else {
+				var component = (SkeletonRenderer)target;
+
+				if (!component.valid && Event.current.type == EventType.Layout) {
+					component.Initialize(true);
+					component.LateUpdate();
+				}
+
+				using (new EditorGUILayout.HorizontalScope(EditorStyles.helpBox)) {
+					SpineInspectorUtility.PropertyFieldFitLabel(skeletonDataAsset, SkeletonDataAssetLabel);
+					if (component.valid) {
+						if (GUILayout.Button(ReloadButtonLabel, reloadButtonStyle, reloadWidth)) {
+							if (component.skeletonDataAsset != null) {
+								foreach (AtlasAsset aa in component.skeletonDataAsset.atlasAssets) {
+									if (aa != null)
+										aa.Clear();
+								}
+								component.skeletonDataAsset.Clear();
+							}
+							component.Initialize(true);
+						}
+					}
+				}
+
+				if (component.skeletonDataAsset == null) {
+					EditorGUILayout.HelpBox("Skeleton Data Asset required", MessageType.Warning);
+					return;
+				}
+
+				#if NO_PREFAB_MESH
+				if (isInspectingPrefab) {
+					MeshFilter meshFilter = component.GetComponent<MeshFilter>();
+					if (meshFilter != null && meshFilter.sharedMesh != null)
+						meshFilter.sharedMesh = null;
+				}
+				#endif
+
+				// Initial skin name.
+				if (component.valid) {
+					var skeletonDataSkins = component.skeleton.Data.Skins;
+					int skinCount = skeletonDataSkins.Count;
+					if (loadedSkinList != skeletonDataSkins) {
+						skins = new GUIContent[skinCount];
+						loadedSkinList = skeletonDataSkins;
+						for (int i = 0; i < skins.Length; i++) {
+							string skinNameString = skeletonDataSkins.Items[i].Name;
+							skins[i] = new GUIContent(skinNameString, Icons.skin);
+						}
+					}
+					
+					int skinIndex = 0;
+					for (int i = 0; i < skins.Length; i++) {
+						string skinNameString = skeletonDataSkins.Items[i].Name;
+						if (skinNameString == initialSkinName.stringValue)
+							skinIndex = i;
+					}
+
+					skinIndex = EditorGUILayout.Popup(SpineInspectorUtility.TempContent("Initial Skin"), skinIndex, skins);
+					if (skins.Length > 0) // Support attachmentless/skinless SkeletonData.
+						initialSkinName.stringValue = skins[skinIndex].text;
+				}
+			}
+
+			EditorGUILayout.Space();
+
+			// Sorting Layers
+			SpineInspectorUtility.SortingPropertyFields(sortingProperties, applyModifiedProperties: true);
+
+			if (!TargetIsValid) return;
+			
+			// More Render Options...
+			using (new SpineInspectorUtility.BoxScope()) {
+				EditorGUI.BeginChangeCheck();
+
+				EditorGUILayout.BeginHorizontal(GUILayout.Height(EditorGUIUtility.singleLineHeight + 5));
+				advancedFoldout = EditorGUILayout.Foldout(advancedFoldout, "Advanced");
+				if (advancedFoldout) {
+					EditorGUILayout.Space();
+					if (GUILayout.Button("Debug", EditorStyles.miniButton, GUILayout.Width(65f)))
+						SkeletonDebugWindow.Init();
+				} else {
+					EditorGUILayout.Space();
+				}
+				EditorGUILayout.EndHorizontal();
+
+				if (advancedFoldout) {
+					
+					using (new SpineInspectorUtility.IndentScope()) {
+						using (new EditorGUILayout.HorizontalScope()) {
+							initialFlipX.boolValue = EditorGUILayout.ToggleLeft(initialFlipX.displayName, initialFlipX.boolValue, GUILayout.Width(120f));
+							initialFlipY.boolValue = EditorGUILayout.ToggleLeft(initialFlipY.displayName, initialFlipY.boolValue, GUILayout.Width(120f));
+							EditorGUILayout.Space();
+						}
+
+						EditorGUILayout.Space();
+						EditorGUILayout.LabelField("Renderer Settings", EditorStyles.boldLabel);
+						using (new SpineInspectorUtility.LabelWidthScope()) {
+							// Optimization options
+							if (singleSubmesh != null) EditorGUILayout.PropertyField(singleSubmesh, SingleSubmeshLabel);
+							//if (meshes != null) EditorGUILayout.PropertyField(meshes, MeshesLabel);
+							if (immutableTriangles != null) EditorGUILayout.PropertyField(immutableTriangles, ImmubleTrianglesLabel);
+							EditorGUILayout.PropertyField(clearStateOnDisable, ClearStateOnDisableLabel);
+							EditorGUILayout.Space();
+						}
+
+						SeparatorsField(separatorSlotNames);
+						EditorGUILayout.Space();
+
+						// Render options
+						const float MinZSpacing = -0.1f;
+						const float MaxZSpacing = 0f;
+						EditorGUILayout.Slider(zSpacing, MinZSpacing, MaxZSpacing, ZSpacingLabel);
+						EditorGUILayout.Space();
+
+						using (new SpineInspectorUtility.LabelWidthScope()) {
+							EditorGUILayout.LabelField(SpineInspectorUtility.TempContent("Vertex Data", SpineInspectorUtility.UnityIcon<MeshFilter>()), EditorStyles.boldLabel);
+							if (pmaVertexColors != null) EditorGUILayout.PropertyField(pmaVertexColors, PMAVertexColorsLabel);
+							EditorGUILayout.PropertyField(tintBlack, TintBlackLabel);
+
+							// Optional fields. May be disabled in SkeletonRenderer.
+							if (normals != null) EditorGUILayout.PropertyField(normals, NormalsLabel);
+							if (tangents != null) EditorGUILayout.PropertyField(tangents, TangentsLabel);
+						}
+
+						EditorGUILayout.Space();
+
+						if (TargetIsValid && !isInspectingPrefab) {
+							if (multi) {
+								// Support multi-edit SkeletonUtility button.
+								//	EditorGUILayout.Space();
+								//	bool addSkeletonUtility = GUILayout.Button(buttonContent, GUILayout.Height(30));
+								//	foreach (var t in targets) {
+								//		var component = t as Component;
+								//		if (addSkeletonUtility && component.GetComponent<SkeletonUtility>() == null)
+								//			component.gameObject.AddComponent<SkeletonUtility>();
+								//	}
+							} else {
+								var component = (Component)target;
+								if (component.GetComponent<SkeletonUtility>() == null) {						
+									if (SpineInspectorUtility.CenteredButton(SkeletonUtilityButtonContent, 21, true, 200f))
+										component.gameObject.AddComponent<SkeletonUtility>();
+								}
+							}
+						}
+
+						EditorGUILayout.Space();
+					}
+				}
+
+				if (EditorGUI.EndChangeCheck())
+					SceneView.RepaintAll();
+			}
+		}
+
+		public static void SeparatorsField (SerializedProperty separatorSlotNames) {
+			bool multi = separatorSlotNames.serializedObject.isEditingMultipleObjects;
+			bool hasTerminalSlot = false;
+			if (!multi) {
+				var sr = separatorSlotNames.serializedObject.targetObject as ISkeletonComponent;
+				var skeleton = sr.Skeleton;
+				int lastSlot = skeleton.Slots.Count - 1;
+				if (skeleton != null) {					
+					for (int i = 0, n = separatorSlotNames.arraySize; i < n; i++) {
+						int index = skeleton.FindSlotIndex(separatorSlotNames.GetArrayElementAtIndex(i).stringValue);
+						if (index == 0 || index == lastSlot) {
+							hasTerminalSlot = true;
+							break;
+						}
+					}
+				}
+			}
+
+			string terminalSlotWarning = hasTerminalSlot ? " (!)" : "";
+
+			using (new EditorGUILayout.VerticalScope(EditorStyles.helpBox)) {
+				const string SeparatorsDescription = "Stored names of slots where the Skeleton's render will be split into different batches. This is used by separate components that split the render into different MeshRenderers or GameObjects.";
+				if (separatorSlotNames.isExpanded) {
+					EditorGUILayout.PropertyField(separatorSlotNames, SpineInspectorUtility.TempContent(separatorSlotNames.displayName + terminalSlotWarning, Icons.slotRoot, SeparatorsDescription), true);
+					GUILayout.BeginHorizontal();
+					GUILayout.FlexibleSpace();
+					if (GUILayout.Button("+", GUILayout.MaxWidth(28f), GUILayout.MaxHeight(15f))) {
+						separatorSlotNames.arraySize++;
+					}
+					GUILayout.EndHorizontal();
+
+					EditorGUILayout.Space();
+				} else
+					EditorGUILayout.PropertyField(separatorSlotNames, new GUIContent(separatorSlotNames.displayName + string.Format("{0} [{1}]", terminalSlotWarning, separatorSlotNames.arraySize), SeparatorsDescription), true);
+			}
+		}
+
+		public void OnSceneGUI () {
+			var skeletonRenderer = (SkeletonRenderer)target;
+			var skeleton = skeletonRenderer.skeleton;
+			var transform = skeletonRenderer.transform;
+			if (skeleton == null) return;
+
+			SpineHandles.DrawBones(transform, skeleton);
+		}
+
+		override public void OnInspectorGUI () {
+			//serializedObject.Update();
+			bool multi = serializedObject.isEditingMultipleObjects;
+			DrawInspectorGUI(multi);
+			if (serializedObject.ApplyModifiedProperties() || SpineInspectorUtility.UndoRedoPerformed(Event.current)) {
+				if (!Application.isPlaying) {
+					if (multi)
+						foreach (var o in targets)
+							((SkeletonRenderer)o).Initialize(true);
+					else
+						((SkeletonRenderer)target).Initialize(true);
+				}
+			}
+		}
+
+	}
+}

+ 0 - 0
spine-unity/Assets/spine-unity/Editor/SkeletonRendererInspector.cs.meta → spine-unity/Assets/Spine/Editor/spine-unity/Editor/SkeletonRendererInspector.cs.meta


Nem az összes módosított fájl került megjelenítésre, mert túl sok fájl változott