[DX11] Please Test My First Demo!
DirectX Tank Physics Bullet Physics C++ Game Engine
I've been focusing a lot on trying to get the tank movement to work decently well. I went for a constraint-based tank rather than a ray-casting one. This basically means that the wheels are real rigid bodies held in place by a 6DOF spring constraint. The motor is applied directly to those constraints. The nice thing is that this is more physically correct than a ray-cast vehicle. I did try the ray casting vehicle functionality in Bullet, but I wasn't impressed. Unfortunately, this also means it's a pain to fine-tune things to act realistically (or realistically enough, I want to retain some of the arcade feel). Specifically, the tank is moved by the wheels--not by the treads--requiring a much higher level of friction. Because the cylinders are rigid bodies, they don't behave like you would expect from a tire, since they are infinitely rigid. The most you can get in terms of contact is a line. Luckily for me, I'm not going for a tire model with realistic drifting behavior. I think it's working pretty well for the moment--at least on my machine.
At any rate, I'd love to hear what you guys think, and also if it even runs on your machines. I've only tested it on mine at the moment. The engine is DirectX 11 based, but currently I'm
Let me know if you get any weird dialog messages or glitches.