From 0dd85b8fe1449c34a82ce28d7ba554de6ff25e81 Mon Sep 17 00:00:00 2001 From: "Kae..pl" Date: Wed, 21 Sep 2011 15:18:28 +0000 Subject: [PATCH] Fix to attaching objects to the scene's node. git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@8268 75d07b2b-3a1a-0410-a2c5-0572b91ccdca --- .../com/jme3/scene/plugins/blender/AbstractBlenderLoader.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/engine/src/blender/com/jme3/scene/plugins/blender/AbstractBlenderLoader.java b/engine/src/blender/com/jme3/scene/plugins/blender/AbstractBlenderLoader.java index bdad3b30e..22696c712 100644 --- a/engine/src/blender/com/jme3/scene/plugins/blender/AbstractBlenderLoader.java +++ b/engine/src/blender/com/jme3/scene/plugins/blender/AbstractBlenderLoader.java @@ -82,7 +82,7 @@ import com.jme3.scene.plugins.blender.objects.ObjectHelper; if(pObject.isNotNull()) { Structure objectStructure = pObject.fetchData(blenderContext.getInputStream()).get(0); Object object = this.toObject(objectStructure); - if(object instanceof Spatial) { + if(object instanceof Spatial && ((Spatial) object).getParent()==null) { result.attachChild((Spatial) object); } else if(object instanceof Light) { result.addLight((Light)object);