Mouse Look and Character Motor off but i can still see :( help plox?

hey guys :)

iv turned the Mouse Look and Character Motor scripts off, but i can still look up and down.

iv cut out the unimportant stuff but heres what im using:

var IsPaused : boolean = false;

function Start()
{
    Screen.showCursor = false;
};

function Update()
{

    if (Input.GetKeyDown ("escape")){
        if (IsPaused == true){
            IsPaused = false;
            Time.timeScale = 1.0;
            Screen.showCursor = false;
        }
        else{
            IsPaused = true;
            Time.timeScale = 0.00001;
            Screen.showCursor = true;
        };
    };  

};

function OnGUI()
{
    if (IsPaused == true){

        var ResumeButton : boolean = GUI.Button(Rect(Screen.width/2, Screen.height/2, 175, 20), "Resume Game");
        var VisitWebsite : boolean = GUI.Button(Rect(Screen.width/2, Screen.height/2 + 25, 175, 20), "Visit the Website");
        var QuitButton : boolean = GUI.Button(Rect(Screen.width/2, Screen.height/2 + 25 + 25, 175, 20), "Exit");

        GameObject.Find('Player').GetComponent('MouseLook').enabled = false;
        GameObject.Find('Player').GetComponent('CharacterMotor').enabled = false;

        if (QuitButton){
            Application.Quit();
        };

        if (ResumeButton){
            IsPaused = false;
            Time.timeScale = 1.0;
            Screen.showCursor = false;
        };

        if (VisitWebsite){
            Application.OpenURL("www.google.com");
        };

    }
    else{
        GameObject.Find('Player').GetComponent('MouseLook').enabled = true;
        GameObject.Find('Player').GetComponent('CharacterMotor').enabled = true;
        return;
    };
};

also the timescale does absolutly shit all (excuse the language) but every time i ask how to make a pause menu people always say to use timescale and it does absolutly nothing for me.

but this is pretty much a work around and i know it works.

the character cant move at all and you cant look around, the game still goes on so it isnt pausing really..its more for my interactives.

thing is, you can still look up and down and i dont know why. i tried unticking every script and it still does it.

help please :S?

make sure you are unchecking the scripts on the Character Controller, not just the scripts on the camera.

iv turned the Mouse Look and Character Motor scripts off

sorry it wouldnt let me login :L

I have the same problem! Have you solved it yet?

The Mouse Look script is on two objects: the First Person Controller, and the Main Camera that is a child of the Controller.

You’re only disabling the one on the First Person Controller, which handles the X axis (MouseX). That’s why you can still look up and down.

You also need to disable the Mouse Look script on the Main Camera, which handles the Y axis (MouseY).

Hope that helped

Thank you haxard.

I made 2 scripts.
One is called “PauseMenu.js”
The other is called “PauseMenu2.js”

I have PauseMenu on my FirstPersonController and PauseMenu2 on my camera.


PauseMenu:

var paused : boolean = false;
var backgroundMusic : AudioSource;
 
function Update () 
{
   if(Input.GetKeyDown(KeyCode.Escape) && paused == false)
   {
	   GetComponent(MouseLook).enabled = false;
	   paused = true;
	   backgroundMusic.mute = true;
	   Time.timeScale = 0;
   }
   else if(Input.GetKeyDown(KeyCode.Escape) && paused == true) 
   {
	   GetComponent(MouseLook).enabled = true;
	   paused = false;
	   backgroundMusic.mute = false;
	   Time.timeScale = 1;
   }
}

PauseMenu2:

var paused : boolean = false;

function Update () 
{
   if(Input.GetKeyDown(KeyCode.Escape) && paused == false)
   {
	   GetComponent(MouseLook).enabled = false;
	   paused = true;
	   Time.timeScale = 0;
   }
   else if(Input.GetKeyDown(KeyCode.Escape) && paused == true) 
   {
	   GetComponent(MouseLook).enabled = true;
	   paused = false;
	   Time.timeScale = 1;
   }
}

Hope This Helps!