diff --git a/engine/src/core/com/jme3/animation/Bone.java b/engine/src/core/com/jme3/animation/Bone.java index 3c4187993..b46e1276a 100644 --- a/engine/src/core/com/jme3/animation/Bone.java +++ b/engine/src/core/com/jme3/animation/Bone.java @@ -237,7 +237,6 @@ public final class Bone implements Savable { */ public final void updateWorldVectors() { if (parent != null) { - //rotation parent.worldRot.mult(localRot, worldRot); @@ -251,9 +250,6 @@ public final class Bone implements Savable { parent.worldRot.mult(localPos, worldPos); worldPos.multLocal(parent.worldScale); worldPos.addLocal(parent.worldPos); - - - } else { worldRot.set(localRot); worldPos.set(localPos); diff --git a/engine/src/core/com/jme3/math/Transform.java b/engine/src/core/com/jme3/math/Transform.java index d01334f5b..2d50fe6b1 100644 --- a/engine/src/core/com/jme3/math/Transform.java +++ b/engine/src/core/com/jme3/math/Transform.java @@ -200,11 +200,18 @@ public final class Transform implements Savable, Cloneable { scale.multLocal(parent.scale); // rot.multLocal(parent.rot); parent.rot.mult(rot, rot); - + + // This here, is evil code +// parent +// .rot +// .multLocal(translation) +// .multLocal(parent.scale) +// .addLocal(parent.translation); + + translation.multLocal(parent.scale); parent .rot .multLocal(translation) - .multLocal(parent.scale) .addLocal(parent.translation); return this; } @@ -262,8 +269,9 @@ public final class Transform implements Savable, Cloneable { @Override public String toString(){ - return getClass().getSimpleName() + "[ "+translation.x + ", "+ translation.y + ", "+translation.z+"]\n"+ - "[ "+rot.x + ", " + rot.y + ", " + rot.z + ", " + rot.w + "]"; + return getClass().getSimpleName() + "[ " + translation.x + ", " + translation.y + ", " + translation.z + "]\n" + + "[ " + rot.x + ", " + rot.y + ", " + rot.z + ", " + rot.w + "]\n" + + "[ " + scale.x + " , " + scale.y + ", " + scale.z + "]"; } /**