Another Error

I’m getting another error after putting in some code


Here’s my code:
// Start is called before the first frame update

void Start()

{

   

}

// Update is called once per frame

void Update()

{

    ProcessThrust();

    ProcessRotation();

}



void ProcessThrust()

{

   if(Input.GetKey(KeyCode.Space))

   {

       Debug.Log("Thrusting");

   }

}

void ProcessRotation()

{

     if (Input.GetKey(KeyCode.A))

   {

       Debug.Log("rotate left");

   }

    else if (Input.GetKey(KeyCode.D))

   {

       Debug.Log("rotate right");

}

Please help!

You should be able to figure this one out…

Hint: Every { needs a corresponding } so make sure every method and if / else statements have both of their { and }

Thanks!

1 Like

Figured it out?

I thought you would.

Yes

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.

Privacy & Terms