[beginner] Spatial loadModel problem

Why does this not work?

[snippet id=“32”]

did you attach the JME-Tests library?

1 Like

I guess because you ignored the big hint about the test assets in the HelloAssets tutorial. But apart from that… Very bad post indeed. You don’t even say what fails or what the error output is.

1 Like

Also player is a local variable for simpleInitApp method. You cannt reach it from simpluUpdate method. You must put it as class member.

1 Like

Ok thanks and sorry. I attached the test library. The problem is with player.rotate.



Mrz 19, 2012 7:44:53 PM com.jme3.app.Application handleError

Schwerwiegend: Uncaught exception thrown in Thread[LWJGL Renderer Thread,5,main]

java.lang.RuntimeException: Uncompilable source code - Erroneous sym type: player.rotate

at mygame.Main.simpleUpdate(Main.java:29)

at com.jme3.app.SimpleApplication.update(SimpleApplication.java:258)

at com.jme3.system.lwjgl.LwjglAbstractDisplay.runLoop(LwjglAbstractDisplay.java:149)

at com.jme3.system.lwjgl.LwjglDisplay.runLoop(LwjglDisplay.java:182)

at com.jme3.system.lwjgl.LwjglAbstractDisplay.run(LwjglAbstractDisplay.java:223)

at java.lang.Thread.run(Thread.java:722)



Mrz 19, 2012 7:44:53 PM com.jme3.renderer.lwjgl.LwjglRenderer cleanup

Information: Deleting objects and invalidating state

Mrz 19, 2012 7:44:53 PM com.jme3.input.lwjgl.LwjglMouseInput destroy

Information: Mouse destroyed.

Mrz 19, 2012 7:44:53 PM com.jme3.input.lwjgl.LwjglKeyInput destroy

Information: Keyboard destroyed.

Mrz 19, 2012 7:44:53 PM com.jme3.system.lwjgl.LwjglAbstractDisplay deinitInThread

Information: Display destroyed.



edit: I don’t like this “Rate this post” thing… For my defense, I wrote this post while H wrote his, not after it.

@H said:
Also player is a local variable for simpleInitApp method. You cannt reach it from simpluUpdate method. You must put it as class member.

Reread this answer. ^^

I think you should read java basics first, then programming games will be a lot more enjoyable

1 Like