No More Local! (NML!)

Yes, the news is so good, ive even given it its own acronym! The physics engine will no longer deal with local vectors but only with world vectors now. This means two things for you:

  1. Alot less bugs are effective because of this change. I.e. most of them have been resolved. Big yay!

  2. A slight change in the initing is required by the user. Instead of this:

StaticPhysicsObject obj1 = new StaticPhysicsObject(obj1);

you do this:

obj1.updateGeometricState(0.0f, false);
StaticPhysicsObject obj1 = new StaticPhysicsObject(obj1);

Not a big change is it? Lets hope not... Ive changed all the tests to reflect this and they all work.

Also, when syncing with the spatial, be sure to call updateGeometricState(0.0f, false) so that jme can recalculate the world vectors for ODE to use..

Edit: added some more information

DP :)

You are brilliant. Thank you for doing this.

I think the physics system is now at a very high level of being

proffesional. It’s so great to work with and the way

it integrates with jME is just as nice.

I will test all of this intensively and let you know of any


Again DarkProphet, thank you very much for doing this!

:slight_smile: :slight_smile: :slight_smile:

No problemo.

Yes please, test test and test some more! Any bugs you report here immediatly at 1300 hours! :stuck_out_tongue:


Haha very funny!

I did test the stuff.

Can’t seem to get the test to work! I get this exception:

Jun 24, 2005 10:21:52 AM com.jme.system.PropertiesIO load
INFO: Read properties
   at java.awt.Container.addImpl(
   at java.awt.Container.add(
   at com.jme.system.lwjgl.LWJGLPropertiesDialog.createUI(
   at com.jme.system.lwjgl.LWJGLPropertiesDialog.<init>(
   at Source)
   at Source)
   at jmextest.physics.TerrainTest.main(Unknown Source)
   at com.mw3d.swt.Tests.main(
Jun 24, 2005 10:21:56 AM cleanup
INFO: Cleaning up resources.

I did my own test with terrainpage but for some reason the terrain in physics world is not at the same place as the one in graphics!

Can you check it out?

Hmm…sure yer, i’l check it out ASAP. Ive got an exam in 30 minutes tho, so i wont do it till this evening.


Ok, i fixed this…it was a minor error in logic on my part.

The algorithm for splitting the terrainpage is basically getting all terrainblocks and their world translations and initing ode on that. The problem was, when calling updateWorldVectors() on a terrainpage, it didn’t propogate down the tree to call updateWorldVectors() on its children. So infact, the locations that ODE got was the same as jme had during initing.

So instead of calling updateWorldVectors(), call “updateGeometricState(0.0f, false);”. This is only true for Nodes. So calling updateWorldVectors on Geometry is fine. E.g, boxes, spheres, TerrainBlock.

I’l edit the topmost post to show this error.