VehicleBody.engineForce

Accelerates the vehicle by applying an engine force. The vehicle is only speed up if the wheels that have VehicleWheel.useAsTraction set to true and are in contact with a surface. The RigidBody.mass 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.

  1. double engineForce [@property getter]
  2. double engineForce [@property setter]
    struct VehicleBody
    @nogc nothrow @property
    void
    engineForce
    (
    double v
    )

Meta