When I use tree generation with SimArborealTree in JMonkeyBuilder and then I try to open the game, an error occurs telling me that TreeLighting.j3md material definition is not present.
What makes me think, you could add a button that shows a snipet with the required dependencies for the displayed model/scene/whatever. That snipet could be gradle/maven ready so you only should copy/paste it.
Using the Static LightProbe, after recording the scene and having it closed, I then tried to open it but the following exception appears:
java.lang.Exception: java.lang.ClassCastException: [Lcom.jme3.export.Savable; cannot be cast to [Lcom.jme3.math.Vector3f;
at com.ss.editor.ui.component.editor.area.EditorAreaComponent.processOpenFileImpl(Unknown Source)
at com.ss.editor.ui.component.editor.area.EditorAreaComponent.lambda$processOpenFile$9(Unknown Source)
at com.ss.editor.executor.impl.BackgroundEditorTaskExecutor.doExecute(Unknown Source)
at com.ss.editor.executor.impl.AbstractEditorTaskExecutor.run(Unknown Source)
Caused by: java.lang.ClassCastException: [Lcom.jme3.export.Savable; cannot be cast to [Lcom.jme3.math.Vector3f;
at com.jme3.light.LightProbe.read(LightProbe.java:129)
at com.jme3.export.binary.BinaryImporter.readObject(BinaryImporter.java:342)
at com.jme3.export.binary.BinaryInputCapsule.readSavable(BinaryInputCapsule.java:457)
at com.ss.editor.extension.scene.app.state.impl.pbr.StaticLightProbeSceneAppState.read(StaticLightProbeSceneAppState.java:271)
at com.jme3.export.binary.BinaryImporter.readObject(BinaryImporter.java:342)
at com.jme3.export.binary.BinaryInputCapsule.resolveIDs(BinaryInputCapsule.java:483)
at com.jme3.export.binary.BinaryInputCapsule.readSavableArray(BinaryInputCapsule.java:471)
at com.ss.editor.extension.scene.SceneNode.read(SceneNode.java:238)
at com.jme3.export.binary.BinaryImporter.readObject(BinaryImporter.java:342)
at com.jme3.export.binary.BinaryImporter.load(BinaryImporter.java:242)
at com.jme3.export.binary.BinaryImporter.load(BinaryImporter.java:125)
at com.jme3.export.binary.BinaryImporter.load(BinaryImporter.java:109)
at com.ss.editor.extension.loader.SceneLoader.load(SceneLoader.java:110)
at com.jme3.asset.DesktopAssetManager.loadLocatedAsset(DesktopAssetManager.java:259)
at com.jme3.asset.DesktopAssetManager.loadAsset(DesktopAssetManager.java:373)
at com.ss.editor.ui.component.editor.impl.scene.SceneFileEditor.doOpenFile(Unknown Source)
at com.ss.editor.plugin.api.editor.BaseFileEditor.openFile(Unknown Source)
at com.ss.editor.plugin.api.editor.Base3DFileEditor.openFile(Unknown Source)
… 4 more
caused by java.lang.ClassCastException: [Lcom.jme3.export.Savable; cannot be cast to [Lcom.jme3.math.Vector3f;
at com.jme3.light.LightProbe.read(LightProbe.java:129)
at com.jme3.export.binary.BinaryImporter.readObject(BinaryImporter.java:342)
at com.jme3.export.binary.BinaryInputCapsule.readSavable(BinaryInputCapsule.java:457)
at com.ss.editor.extension.scene.app.state.impl.pbr.StaticLightProbeSceneAppState.read(StaticLightProbeSceneAppState.java:271)
at com.jme3.export.binary.BinaryImporter.readObject(BinaryImporter.java:342)
at com.jme3.export.binary.BinaryInputCapsule.resolveIDs(BinaryInputCapsule.java:483)
at com.jme3.export.binary.BinaryInputCapsule.readSavableArray(BinaryInputCapsule.java:471)
at com.ss.editor.extension.scene.SceneNode.read(SceneNode.java:238)
at com.jme3.export.binary.BinaryImporter.readObject(BinaryImporter.java:342)
at com.jme3.export.binary.BinaryImporter.load(BinaryImporter.java:242)
at com.jme3.export.binary.BinaryImporter.load(BinaryImporter.java:125)
at com.jme3.export.binary.BinaryImporter.load(BinaryImporter.java:109)
at com.ss.editor.extension.loader.SceneLoader.load(SceneLoader.java:110)
at com.jme3.asset.DesktopAssetManager.loadLocatedAsset(DesktopAssetManager.java:259)
at com.jme3.asset.DesktopAssetManager.loadAsset(DesktopAssetManager.java:373)
at com.ss.editor.ui.component.editor.impl.scene.SceneFileEditor.doOpenFile(Unknown Source)
at com.ss.editor.plugin.api.editor.BaseFileEditor.openFile(Unknown Source)
at com.ss.editor.plugin.api.editor.Base3DFileEditor.openFile(Unknown Source)
at com.ss.editor.ui.component.editor.area.EditorAreaComponent.processOpenFileImpl(Unknown Source)
at com.ss.editor.ui.component.editor.area.EditorAreaComponent.lambda$processOpenFile$9(Unknown Source)
at com.ss.editor.executor.impl.BackgroundEditorTaskExecutor.doExecute(Unknown Source)
at com.ss.editor.executor.impl.AbstractEditorTaskExecutor.run(Unknown Source)
I can not edit the scene anymore with JMonkeyBuilder
Another question, when adding a link to a model in a scene, there is no way to add a UserData to the node containing the link. Since it is not possible to add a controller or copy the link. Will these options be added in the next version ?
If possible, I think that the addition of adding user data to linked objects would be useful. In some cases, I’m adding user data to my models in the editor, and then I change the materials at run time based on the user data. Normally it is not possible to change a linked model’s material in any editor without changing the source model as well, so my workaround has been to use userData for linked models in the SDK editor.
Adding user data to my linked models is the only thing I still find myself going back to the SDK’s editor for, otherwise I’ve been able to do everything I need in JMB excellently
Linked models. When I load the map at run time, i search the scene for objects that are flagged with a userData string, and I’m able to change the materials on any linked model without affecting its source model or the other linked copies of the source model.