Unity GUI

Video Games

Download the Menu package (includes GUIController, GameController and LoadNextLevel scripts, and the Canvas Screen prefab)

I fixed the UI animations problem by changing the animation update mode with this line in GUIController so it ignore the Time.timeScale and get rid of the IEnumerator calls:

public Animator backgroundAnimator;

void Start() {
	backgroundAnimator.updateMode = AnimatorUpdateMode.UnscaledTime;
}

I also added a reference in GameController to the Camera object to disable the Mouse orbit controls:

public Camera camera;
void PauseGame() {
	Time.timeScale = 0;
	camera.GetComponent<MouseOrbitImproved> ().enabled = false;
	gui.OpenMenu ();
}

public void PlayGame() {
	Time.timeScale = 1;
	camera.GetComponent<MouseOrbitImproved> ().enabled = true;
	gui.CloseMenu ();
}