Skip to content

Instantly share code, notes, and snippets.

@Zapafaz
Created November 7, 2017 01:44
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Zapafaz/d06b9efecac24df0a047959dc55bde71 to your computer and use it in GitHub Desktop.
Save Zapafaz/d06b9efecac24df0a047959dc55bde71 to your computer and use it in GitHub Desktop.
// Pause the game and show the pause menu
void Pause()
{
isPaused = true;
Time.timeScale = 0.0F;
menuCanvas.enabled = true;
}
// Unpause the game and hide the pause menu
void Continue()
{
isPaused = false;
Time.timeScale = 1.0F;
menuCanvas.enabled = false;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment