JV-ODE Physics Thread 2

Blitz3D Forums/Blitz3D Userlibs/JV-ODE Physics Thread 2

The forum is locked. These are the original blitzbasic.com forums, kept so they can still be read. No new topics, replies or edits can be made here. To join in, head over to the Blitz3D+ forums.

@Shifty Geezer: Hmm, you need to study the docs a little more me thinks ;)

1) It works ok, but you do need to use it correctly. Bounce restitution ranges from 0.0=no bounce to 1.0=max bounce. You have it set at 100 :S - look at section 7.3.7 of the docs for more info on the contact settings.

2) No, unless I'm mistaken the point of reference for the center of gravity is at the center of the geometry (0,0,0) not the corner. Check sections 9.2 and 10.7.1 of the docs for more info.

3) Yep, Mu is the coulomb friction coefficient but it ranges from 0.0=no friction to Infinity=max friction - not 0.0 to 1.0 - again check section 7.3.7 of the docs for more info.

Mu and Mu2, Slip1 and Slip2 etc represent two different contact directions if needed. Normally you only need one direction Mu, Slip1 etc. Yep, you guessed it, check section 7.3.7 of the docs for more info ;)

One more thing, you have the gravity set at -3, this is over 3 times the value of 'real' gravity. The real gravity setting would be -0.98 (rounded up).

Download the docs and have a good read, most of the answers you'll need can be found in there and it'll all make much more sense then. If you have any more questions please let me know, I'll be glad to help :)

@Cygnus: Yep, simply adding spheres where ever you need collision responses for the TriMesh on the car body would work fine. With those minis, you could probably create a large sphere in the center of the car, then one sphere on each corner.

The beauty of sphere wrapping is the level of control you have for speed vs collision resolution. Whereas standard TriMesh>cube responses can be overkill for most situations.

Also, there is another major advantage... the cars won't accidently 'snag' on the terrain, whereas cube>TriMesh collisions are prone to this problem.

Check up there ^^^ for the sphere-wrapping demos ;)