Physics logging

Last two days I spent wondering why things doesn’t work right in my project. Finally found where was the problem. In short: I loaded level and added all controls to physics space. But all the functions I put after this loading of level didn’t work. In the end, I figured out that physics space doesn’t exist yet in my configuration, so all the code after that didn’t work, probably because physics threw some exception. In console, there was no log about this, so I want to know if there is a way to show physics logging.

Thanks!

How should the physics log something when you dont start it?

Good point. But shouldn’t there be at least null pointer exception on physics space? :slight_smile:

No, why? Its a modular system, if theres no BulletAppState then theres no physics, any “physicsSpace” variables are handmade.

Actually I have BulletAppState. The problem was that it wasn’t attached to stateManager and hence physicsSpace wasn’t initialized. When I called getPhysicsSpace() to add controls to it, this obviously returned null. All I am saying is that I was surprised that there was no error in console and I spent lots of time figuring this out, so I wanted to share this for anyone who would come to similar problems… :slight_smile:

There should be an error in the console. If you’re running in webstart/applet, it will appear in the java console built in the browser