From 2d9a1b8737cfc0c4e4b346ebf3f2b55b32848a60 Mon Sep 17 00:00:00 2001 From: jmekaelthas Date: Sun, 28 Jun 2015 15:48:11 +0200 Subject: [PATCH] Bugfix: include all bones in the chain of the IK constraint if the specified chain length is zero. --- .../blender/constraints/definitions/ConstraintDefinitionIK.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/jme3-blender/src/main/java/com/jme3/scene/plugins/blender/constraints/definitions/ConstraintDefinitionIK.java b/jme3-blender/src/main/java/com/jme3/scene/plugins/blender/constraints/definitions/ConstraintDefinitionIK.java index af6f17669..69e087a28 100644 --- a/jme3-blender/src/main/java/com/jme3/scene/plugins/blender/constraints/definitions/ConstraintDefinitionIK.java +++ b/jme3-blender/src/main/java/com/jme3/scene/plugins/blender/constraints/definitions/ConstraintDefinitionIK.java @@ -182,7 +182,7 @@ public class ConstraintDefinitionIK extends ConstraintDefinition { if (!useTail) { bone = bone.getParent(); } - while (bone != null && this.size() < bonesAffected) { + while (bone != null && (bonesAffected <= 0 || this.size() < bonesAffected)) { BoneContext boneContext = blenderContext.getBoneContext(bone); this.add(boneContext); alteredOmas.add(boneContext.getBoneOma());