From 3d52f1a7e2e3a69ee01640972e27745d38b68b29 Mon Sep 17 00:00:00 2001 From: pharan Date: Wed, 15 Aug 2018 00:04:07 +0800 Subject: [PATCH] [unity] IkConstraint.stretch --- .../Spine/Editor/spine-unity/Editor/SkeletonDebugWindow.cs | 1 + .../Assets/Spine/Runtime/spine-unity/SkeletonExtensions.cs | 1 + 2 files changed, 2 insertions(+) diff --git a/spine-unity/Assets/Spine/Editor/spine-unity/Editor/SkeletonDebugWindow.cs b/spine-unity/Assets/Spine/Editor/spine-unity/Editor/SkeletonDebugWindow.cs index 7bf8406e6..73396814c 100644 --- a/spine-unity/Assets/Spine/Editor/spine-unity/Editor/SkeletonDebugWindow.cs +++ b/spine-unity/Assets/Spine/Editor/spine-unity/Editor/SkeletonDebugWindow.cs @@ -375,6 +375,7 @@ namespace Spine.Unity.Editor { EditorGUI.BeginChangeCheck(); c.Mix = EditorGUILayout.Slider("Mix", c.Mix, MixMin, MixMax); c.BendDirection = EditorGUILayout.Toggle(SpineInspectorUtility.TempContent("Bend Clockwise", tooltip: "IkConstraint.BendDirection == 1 if clockwise; -1 if counterclockwise."), c.BendDirection > 0) ? 1 : -1; + c.Stretch = EditorGUILayout.Toggle(SpineInspectorUtility.TempContent("Stretch", tooltip: "Stretch the parent bone when the target is out of range. Not applied when parent bone has nonuniform scale."), c.Stretch); if (EditorGUI.EndChangeCheck()) requireRepaint = true; EditorGUILayout.Space(); diff --git a/spine-unity/Assets/Spine/Runtime/spine-unity/SkeletonExtensions.cs b/spine-unity/Assets/Spine/Runtime/spine-unity/SkeletonExtensions.cs index 63c1a52b7..864593ae2 100644 --- a/spine-unity/Assets/Spine/Runtime/spine-unity/SkeletonExtensions.cs +++ b/spine-unity/Assets/Spine/Runtime/spine-unity/SkeletonExtensions.cs @@ -503,6 +503,7 @@ namespace Spine { ikc = skeleton.ikConstraints.Items[i]; ikc.mix = ikc.data.mix; ikc.bendDirection = ikc.data.bendDirection; + ikc.stretch = ikc.data.stretch; break; // TransformConstraint