Multiple Physics Spaces

I’m currently using JME2/jbullet-jme and am very hesitant to switch over to 3. I’m wondering if there’s any way possible to have multiple physics spaces within an application running under JME2?



Also, I saw via searching the forum that this was/is coming to JME3? Is it currently functional in 3?



Many thanks.

  1. No
  2. Yes

Thanks for the reply normen. So I’d like to solicit any ideas you guys might have on how I should proceed. My problem is that I have a server/client archetecture that requires the server to be able to run a physics simulation that mirrors the clients in several sectors of a system. If I’m only allowed one physics space the only thing I can think of is to segment off this space and use the various quadrants to simulate the various sectors that I require. Anyone have any thoughts as to how else I could accomplish this?



Also as a side note, I noticed a thread from about a 3 months ago when someone was asking whether JMEDesktop was functional in JME3 and the answer appeared to be “no”. This is the major deterrent to me moving on to JME3 as I don’t want to port my entire gui. Is it still the case that JMEDesktop does not work in 3?



Thanks again.

Many simple games just run physics server-side and just display the results client-side. Other solution is simply making the two server and client different java apps. With two JVM’s you can also have two PhysicsSpaces in jME2.

There’s an implementation of JMEDesktop for jME3 but it is unofficial, if you use it its at your own risk and we cannot support it.

Great. Thanks for the info. I checked out that JMEDesktop implementation, but I don’t think it’ll work for me since it only works in ortho. Ugh. Ok, I’m going to plan C. Which leads me to my next question. I know when I used an early version of the physics in jme a few years ago, I had problems with jittery objects the further I went from the origin. So I’m wondering if there are any issues with or any limitations on the size of the physics space, in particular a fairly large space?

Well floats have 7 significant digits,

so depending on needed accuracy you have a maximum distance

If you need mm accuracy

9999.999 for example

99 999 999 999.999



However i postet recently a double accuracy version of jbullet in the forums

http://nh-game.net/jbulletdouble.jar



In this case you however needs to write a layer between jme and jbullet that makes sure the camera always stays in the middle of the jme float space. (Dont move the camera, move the world around it, that way i already have some good results, as now only objects that are far away from the camera are inaccurately displayed, but if it is furthr away then 9Km you probably wouldn’t notice a accuracy loss anyway.

Excellent info. Thanks!