I couldn’t find any game template in the SDK. Don’t know If I’ve broke it or if RC2-nightly doesn’t contain any right now. So I created an assets directory (no subdirectories), which the SDK didn’t recognize until I restarted it. Then I got the nice Assets-icon.
Then I created an empty scene and tried to add a new terrain spatial to the scene. Nothing happened after I finished the wizard. See below for the SDK log. So I tried again and the little red exception marker is visible in the SDK catching a NullPointer. I didn’t see it at first so perhaps there should be a little bit more prominent error-dialog, what do you think?
SEVERE [com.jme3.app.AppTask]: Exception
[catch] at com.jme3.app.AppTask.invoke(AppTask.java:142)
java.io.FileNotFoundException: /home/johan/projects/jme-testcases/CornerStablizationTest/assets/Textures/terrain-alpha/TerrainScene-terrain-TerrainScene-alphablend0.png (No such file or directory)
at java.io.RandomAccessFile.open(Native Method)
I couldn't find any game template in the SDK.
Uh, something is quite wrong then.
It fails because it is looking for the Textures directory, and that isn't there. It creates the terrain-alpha directory in there. If the asset folders aren't there, then it might be difficult for many operation in jme, in particular the SDK, to perform.
So you don't see a BasicGame template in the New Project menu?
Yes that’s the funny thing, I only see the JME3 Tests template. Must’ve broken my installation messing about with plugins
Anyhow, I like to help so I was thinking that I could try to write a patch to make the error a bit more telling than an NPE. The catch-all red icon is a bit hard to see I think.
So I was wondering if there is some general strategy for error reporting. Like show a JME-branded dialog, or maybe that a plugin should try to correct the error before reporting. In this case try to create the missing texture directory.
I think it would improve the user experience of the SDK if there was some common feel to error reporting.
Yeah I don’t know why just that template is missing, don’t recall messing with the provided templates. However I have been deleting some cache-directories and such while doing plugins so I need to verify my install first, might be just “user error”
I installed the “Project Templates”-plugin from the update center and things are back to normal with the templates. Don’t know how I managed to remove that, didn’t even know it was a module. So yeah, “user error”
Glad you got it working.
Some more noticeable errors might still be beneficial however. I think it might be possible to force netbeans to pop them up instead of hide them in the corner.
Yeah, I was looking into that. Seems no-one knows wtf you should use on the netbeans forums.
This is what is recommended in the Netbeans logging document.
[java] NotifyDescriptor.Exception e = new NotifyDescriptor.Exception(ex);
But that NotifyDescriptor.Exception is deprecated because it lead to race conditions. Which they solved by introducing notifyLater but forgot to de-deprecate the method a few years ago :(
Then some (IMO confused) decision was made to steal the logging framework output and if that indicated an exception it should be shown in the IDE, which is why you get the red icon for all sorts of exceptions, _even_ if you deal with them but want to log them anyway.
So this is what I'm doing, not perfect but better than nothing I guess.