# WheelCollider: Slowing down wheels in air

Hello all,

I’m making a 2.5D car game (Unity 5.3.4f1) with a lot of jumping in it. I’m almost done with the controls and behaviour of the car, but there’s one thing I can not figure out.

The car have 4 wheelcolliders and are working great when grounded. When releasing the throttle the car and wheels are slowing down. So the audio pitching is working great.
But when the car goes at maxpeed of the ground and into the air, the cars rpm is stuck at full throttle/maxspeed and not slowing down until the car is hitting the ground again. Audio pitching is at max rpm (does have Mathf.Clamp). When the car is leaving the ground while not at maxspeed, the wheels are slowing down as wanted.

When releasing the throttle (grounded and in the air) the motorTorque = 0;

Does someone know what can be the problem? Also checked the setting for the wheelcolliders but nothing works.

The code for throttle behaviour:

``````void maximumSpeed () {
//Control of max speed
if (Input.GetKey (KeyCode.RightArrow) && currentSpeed <= maxSpeed && currentSpeed >= noSpeed) {
wheelRR.motorTorque = maxTorque * Input.GetAxis ("Horizontal");
wheelRL.motorTorque = maxTorque * Input.GetAxis ("Horizontal");
}

else if (Input.GetKey (KeyCode.LeftArrow) && currentSpeed >= -maxReverseSpeed && currentSpeed <= noSpeed) {
wheelRR.motorTorque = maxTorque * Input.GetAxis ("Horizontal");
wheelRL.motorTorque = maxTorque * Input.GetAxis ("Horizontal");
}

else {
wheelRR.motorTorque = 0f;
wheelRL.motorTorque = 0f;
}
}
``````

Fixed it with:

``````		if (Mathf.Abs (currentSpeed) > maxSpeed) {
wheelFR.motorTorque = 0f;
wheelFL.motorTorque = 0f;
wheelRR.motorTorque = 0f;
wheelRL.motorTorque = 0f;
}
``````

In Update ()