Want to stop camera from rotate around car

Hi all, i am trying to stop the camera from rotating around the car, this rotation happens at the end of the race, when i click next or switch scene. The car don’t move when u press the gas button, it just stay there and u see rubber burning. would like to deactivate the rotation camera after i click next or switch scene, any help will be appreciated. thanks in advance.

Whatever script you’re using to rotate the camera, try just disabling it. Hard to say more, because we don’t have any information about how your camera rotation functions.

Ok, I have the code, sorry about the late reply

will be good to add some logic like rotate if something is true

or you can pause game with Time.timeScale = 0;

Thanks, i think i have to do some logic.

sorry for taking so long to reply

Public class FinishRotate : MonoBehaviour
{
    public static bool startRotating = false;
   
    void Update()
    {
        if (startRotating)
        {
             transform.Rotate(0, 1, 0, Space.World;
        }
    }
}

Then you can enable and disable rotating from another script like this:

FinishRotate.startRotating = true;

Thanks,
I want to add this to the next button so it can unpause, because i have the rotation camera hidden at the start of the race. So when i click next it will unpause the same time.