BCE0044: expecting }, found ''.

I have absolutely no idea what to do plz help meh it is this error BCE0044: expecting }, found ‘’. I know what it means but my ignorance is apparent

var enterDistence = 10;

//Boolean

static var playerInVehicle = false;

private var inRange = false;

//Transforms

var Char : GameObject;


Char = gameObject.Find("Character");


var player : Vector3 = Char.transform.position;

    var distence : Vector3 = player - transform.position;

    

    if (distence.magnitude < enterDistence)

    {

        inRange = true;

    }

    else if (distence.magnitude > enterDistence)

    {

        inRange = false;        

    }

    

    if (inRange == true)

    {

        if (Input.GetKeyUp("return"))

        {

            if (Get_In_Vehicle.playerInVehicle == true)

            {

                Get_In_Vehicle.playerInVehicle = false;

                gameObject.GetComponent(Car_Movement).enabled = false;

                Char.transform.parent = null;

                Char.active = true;

                gameObject.Find("ShaoKahn").SetActiveRecursively (true);

                Camera.main.GetComponent(SmoothFollow).target = Char.transform;

                Camera.main.GetComponent(SmoothFollow).distance = 15;

                Camera.main.GetComponent(SmoothFollow).height = 5;

                Char.transform.position.y += 10;

            }

            else if (Get_In_Vehicle.playerInVehicle == false)

            {

                Get_In_Vehicle.playerInVehicle = true;

                gameObject.GetComponent(Car_Movement).enabled = true;

                Char.transform.parent = gameObject.transform;

                Char.active = false;

                gameObject.Find("ShaoKahn").SetActiveRecursively (false);

                Camera.main.GetComponent(SmoothFollow).target = gameObject.transform;

                Camera.main.GetComponent(SmoothFollow).distance = 25;

                Camera.main.GetComponent(SmoothFollow).height = 10;

            }            

        }

    }

}

You are getting the error because you have mismatched brackets. You have one extra ‘}’ at the end of the file, but your real problem is a missing function declaration. This code appears to belong in Update. So Insert at line 12:

function Update() {

There are other issues with this code, but putting in the function declaration will get you past the error you are listing.