示例#1
0
    private void Awake()
    {
        //Reveal main menu
        CanvasGroupUtil.HideCanvasGroup(OptionsMenu);
        CanvasGroupUtil.HideCanvasGroup(AboutMenu);
        CanvasGroupUtil.RevealCanvasGroup(MainMenu);

        //Update highscore display
        highscore = HighScore.LoadHighScore();
        string paddedString = highscore.ToString().PadLeft(6, '0');

        highScore.text = paddedString;
    }
示例#2
0
 private void SetPause(bool pause)
 {
     //Debug.Log("Set pause " + isPaused);
     isPaused = pause;
     if (isPaused)
     {
         Time.timeScale = 0f;
         CanvasGroupUtil.RevealCanvasGroup(canvas_Pause);
     }
     else
     {
         Time.timeScale = 1f;
         CanvasGroupUtil.HideCanvasGroup(canvas_Pause);
     }
 }
示例#3
0
 public void AboutBackToMain()
 {
     //Hide the options menu and reveal the main menu
     CanvasGroupUtil.HideCanvasGroup(AboutMenu);
     CanvasGroupUtil.RevealCanvasGroup(MainMenu);
 }
示例#4
0
 public void OpenOptionsMenu()
 {
     //Hide the main menu and reveal the options menu
     CanvasGroupUtil.HideCanvasGroup(MainMenu);
     CanvasGroupUtil.RevealCanvasGroup(OptionsMenu);
 }