I'm trying to get up to date with jme 2.0 and I'm playing with texture states. I'm creating a textureState somewhere in my code like this
given that initially, ts is declared as a public attribute of my class (this class is named Rooms)
ts = display.getRenderer().createTextureState();
Texture t = TextureManager.loadTexture(
when I check with eclipse debugger, ts is not null.
Then, later in another function (not belonging to the same class but the call is made by a function of the class Rooms) I call this textureState like this:
int k=10; // so that I can put a breakpoint here with the eclipse debugger
//mapNodes contains a TriMesh child called "floor"
the point is that I have this javaNullPointerException if I launch the code, and in debugger, it stops at the "int k = 10;" and when within the debugger I check the content of the variable "fatherRooms.t1", I found what seems to me a normally initialized texture state with a texture in it ....
so I'm wondering if there wouldn't be an access restriction problem but I'm not sure why since this member of the fatherRooms object is public ...
any idea ?