diff --git a/sdk/jme3-ogrexml/src/com/jme3/gde/ogrexml/OgreXMLDataObject.java b/sdk/jme3-ogrexml/src/com/jme3/gde/ogrexml/OgreXMLDataObject.java index a4c215ab6..3aa1e450d 100644 --- a/sdk/jme3-ogrexml/src/com/jme3/gde/ogrexml/OgreXMLDataObject.java +++ b/sdk/jme3-ogrexml/src/com/jme3/gde/ogrexml/OgreXMLDataObject.java @@ -31,7 +31,9 @@ */ package com.jme3.gde.ogrexml; +import com.jme3.asset.ModelKey; import com.jme3.gde.core.assets.SpatialAssetDataObject; +import com.jme3.scene.plugins.ogre.OgreMeshKey; import java.io.IOException; import org.openide.filesystems.FileObject; import org.openide.loaders.DataObjectExistsException; @@ -43,4 +45,13 @@ public class OgreXMLDataObject extends SpatialAssetDataObject { super(pf, loader); } + @Override + public ModelKey getAssetKey() { + if(super.getAssetKey() instanceof OgreMeshKey){ + return (OgreMeshKey)assetKey; + } + assetKey = new OgreMeshKey(super.getAssetKey().getName()); + return (OgreMeshKey)assetKey; + } + }