Pause game camera movement s

Hi all! I have a very simple problem and I’m not asking for code. I have a pause game script (below) and I have a tiny issue. Everything stops, but the player can move the mouse look camera around while paused. Is there any way I can lock the mouse look script while paused?

var paused : boolean = false;
 
function Update () {
 if(Input.GetKeyDown(KeyCode.P)){
  if(!paused){
   Time.timeScale = 0;
   paused=true;
  }else{
   Time.timeScale = 1;
   paused=false;
  }
 }
}

Here’s my solution, works fine for me.

var paused : boolean = false;
 
function Update () {
if (Input.GetButtonDown("Escape"))
   GetComponent(MouseLook).enabled = false;
else if (Input.GetButtonUp("Escape"))
   GetComponent(MouseLook).enabled = true;
 if(Input.GetKeyDown(KeyCode.Escape)){
  if(!paused){
   Time.timeScale = 0;
   paused=true;
   
  }else{
   Time.timeScale = 1;
   paused=false;
  }
 }
}