Function VehicleBody.engineForce
Accelerates the vehicle by applying an engine force. The vehicle is only speed up if the wheels that have VehicleWheel
set to true
and are in contact with a surface. The RigidBody
of the vehicle has an effect on the acceleration of the vehicle. For a vehicle with a mass set to 1000, try a value in the 25 - 50 range for acceleration.
Note: The simulation does not take the effect of gears into account, you will need to add logic for this if you wish to simulate gears.
A negative value will result in the vehicle reversing.
double engineForce() nothrow @property @nogc;
void engineForce
(
double v
) nothrow @property @nogc;