How to use WheelCollider.isGrounded ? (499729)

Hi
I want to use WheelCollider.isGrounded but when I want to use this as Boolean variable get this error :

this is my code:

    var wheelGround : boolean;
    wheelGround = WheelCollider.isGrounded;

thanks

WheelCollider.isGrounded - this is static variable call. But “isGrounded” getter is not static, this is what error saying to you.

To use it, you should have instance of WheelCollider;

public WheelCollider MyWheel; //  attach to this script your wheel colider

void Update() {
Debug.Log(MyWheel.isGrounded);
}