The problem with NullPointerException

A codehttp://ideone.com/bfefgY

A error

SEVERE: Uncaught exception thrown in Thread[LWJGL Renderer Thread,5,main]
java.lang.NullPointerException
at com.jme3.material.Material.(Material.java:120)
at ru.tec.object.Cube.paint(Cube.java:116)
at ru.tec.game.Game.simpleInitApp(Game.java:32)
at com.jme3.app.SimpleApplication.initialize(SimpleApplication.java:226)
at com.jme3.system.lwjgl.LwjglAbstractDisplay.initInThread(LwjglAbstractDisplay.java:130)
at com.jme3.system.lwjgl.LwjglAbstractDisplay.run(LwjglAbstractDisplay.java:207)
at java.lang.Thread.run(Thread.java:744)

Help pls me :smile:

I’m not sure what you want help with. It’s a null-pointer exception. Use hot-debugging on the line that causes the null pointer to find out what is null, and ammend your code accordingly.

Tried to debug that - it does not work

We can’t see any of your code. What does not work when debugging?

If only there was a way to know what’s on line 120 of the material.java…
oh wait!

Same thing. I’m trying to catch flies where a mistake, but nothing is clear.

Your bug is here: