From 78d6e42fc85725227be101d3c06fb3bbec2e5c03 Mon Sep 17 00:00:00 2001 From: amantley Date: Mon, 4 Feb 2019 13:42:19 -0800 Subject: [PATCH] made the ik enable/disable work for the old animIK node json --- libraries/animation/src/Rig.cpp | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/libraries/animation/src/Rig.cpp b/libraries/animation/src/Rig.cpp index 2faeddaa4f..f366c08cfe 100644 --- a/libraries/animation/src/Rig.cpp +++ b/libraries/animation/src/Rig.cpp @@ -1069,6 +1069,10 @@ void Rig::computeMotionAnimationState(float deltaTime, const glm::vec3& worldPos t += deltaTime; if (_enableInverseKinematics) { + + // animIK node json + _animVars.set("ikOverlayAlpha", 1.0f); + // animSpline json _animVars.set("splineIKEnabled", true); _animVars.set("leftHandIKEnabled", true); _animVars.set("rightHandIKEnabled", true); @@ -1079,6 +1083,9 @@ void Rig::computeMotionAnimationState(float deltaTime, const glm::vec3& worldPos _animVars.set("leftFootPoleVectorEnabled", true); _animVars.set("rightFootPoleVectorEnabled", true); } else { + // animIK node json + _animVars.set("ikOverlayAlpha", 0.0f); + // animSpline json _animVars.set("splineIKEnabled", false); _animVars.set("leftHandIKEnabled", false); _animVars.set("rightHandIKEnabled", false);