I just started a new project and I am still in the planing phase but would like some advices or ideas from you.
In the game, the player can build his own driveable robot. I would like to give the player the maxial freedom and a very restriction-free building for an optimal experience of creativity and versatility.
However, I am stuck in the thought on how to implement the wheel physics, or more general, the movement physics.
Possibility 1.) Fixed wheels. The wheels are on a fixed position and have the same behaviour for every robot. That would be easy to implement because I could just cheat around real physical calculations. But thats not how I want it.
Possibility 2.) Manual wheels. Thats what I am aiming for.
The robot consists of 3 main-element types: Rods and plates for stability, drive shafts (I don’t know if this is the correct word, basically rod’s that are spinned by the gears), hydaulics and springs and the engine.
The engine has output-slots that can power multiple rods so that they are spinning. Via a gear-box (user friendly implementation of gear-translations) he can lead the spin to the wheels.
Now, how would I implement movement (and calculate it)? One wheel would be rather simple. I take the input-rotation, translate it to the wheel-rotation and calculate the distance the wheel pulls the robot foreward or backward. But how does it work with two wheels? Of course the robot would’nt move twice as fast. Also, one wheel could spin faster than the other one, like when the player implements steering with hydraulics and gear-boxes.
I don’t want to cheat around the real behaviour of wheels, but I am afraid that real calculations could be too CPU-expensive.
Any ideas on how to solve that?