Pre-packaged physics system

Blitz3D Forums/Blitz3D Programming/Pre-packaged physics system

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.

LOL.

Anyhow, the car model in the demo is made from a number of ODE objects and ODE joints - the wheels are spheres (an unfortunate problem but there is no cylinder->poly collision in Blitz at the moment to get around this), and the body is a cube.

The wheels are joined the to body by 4 special CARWHEEL ODE joints. These incorporate 2 axes of powered movement (vertical rotation (steering) and a horizontal axle (forward/backward)), and also a springing suspension system that operates along a defined axis (probably vertical in the demo I think).

The problem with the AlignToVector use is that the Blitz visual object doesn't get oriented correctly to the ODE box (body) unless the rate parameter is changed on some versions of Blitz. The physics system and subsequent physically actions of the car are entirely unrelated to the use of this command. You can remove it completely and the car will still drive exactly the same as before.

In fact, you can entirely remove the Blitz side of things (minus the input routine) and the car will drive the same (albeit without poly collision and thus interacting with ODE objects only).

You need to understand how that the physics is totally independant from the Blitz bits - the only feedback added was to force sphere->poly collisions with the track model.

This ODE model of the car would drive exactly the same in a program written in C or whatever. Look at the ODE Buggy (C++) demo - the same problems and 'feel' to the car are there too.

This is in my opinion the major problem with an external physics system - getting info back and forth is difficult and you have to bully the system into doing what you want.


Anyhow, the fact is that if you create a poor model of a car, then it will drive poorly



Yes, but it's not the car model at fault, it's the tyre model, or more precisely the complete lack of one. The suspension joints in ODE are prefectly OK, but without at least some form of realistic simulation of rubber on tarmac
the car will behave like it's either driving on ice or on velcro. There will be no static->sliding friction changes etc.. that make up a real car model.

I really wish someone would package up a "CAR PHYSICS SYSTEM" userlib for Blitz, incorporating all these things.