From aaeb948b9d61c283bb882e515dc56f88b0543707 Mon Sep 17 00:00:00 2001 From: "Kae..pl" Date: Thu, 23 Jun 2011 14:10:03 +0000 Subject: [PATCH] Fix to object positioning when Y axis is set to be UP axis. git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@7699 75d07b2b-3a1a-0410-a2c5-0572b91ccdca --- .../jme3/scene/plugins/blender/helpers/v249/ObjectHelper.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/engine/src/blender/com/jme3/scene/plugins/blender/helpers/v249/ObjectHelper.java b/engine/src/blender/com/jme3/scene/plugins/blender/helpers/v249/ObjectHelper.java index 3c3ca85b0..3c73b4dca 100644 --- a/engine/src/blender/com/jme3/scene/plugins/blender/helpers/v249/ObjectHelper.java +++ b/engine/src/blender/com/jme3/scene/plugins/blender/helpers/v249/ObjectHelper.java @@ -302,10 +302,10 @@ public class ObjectHelper extends AbstractBlenderHelper { Vector3f scale = new Vector3f(size.get(0).floatValue() * scaleX, size.get(1).floatValue() * scaleY, size.get(2).floatValue() * scaleZ); - if(fixUpAxis) { + if(parent.isNull() && fixUpAxis) { float y = translation.y; translation.y = translation.z; - translation.z = y; + translation.z = -y; rotation.multLocal(this.upAxisRotationQuaternion); } Transform t = new Transform(translation, rotation);