コード例 #1
0
 void ResetSaveData(int windowID)
 {
     GuiDisplayScript.ConfirmModal("Are you sure you want to reset your save data?",
                                   () =>
     {
         PlayerPrefs.DeleteAll();
         ShowConfirmWindow = false;
     },
                                   () => ShowConfirmWindow = false);
 }
コード例 #2
0
 void RestartLevel(int windowID)
 {
     GuiDisplayScript.ConfirmModal("Are you sure you want to restart the level?",
                                   () => {
         confirmModal   = null;
         Time.timeScale = Time.timeScale == 0 ? 1 : 0;
         Application.LoadLevel("Level" + FindObjectsOfType <PlayerScript>()[0].LevelNumber);
     },
                                   () => {
         confirmModal   = null;
         Time.timeScale = Time.timeScale == 0 ? 1 : 0;
     });
 }
コード例 #3
0
 void QuitLevel(int windowID)
 {
     GuiDisplayScript.ConfirmModal("Are you sure you want to quit the level?",
                                   () =>
     {
         confirmModal   = null;
         Time.timeScale = Time.timeScale == 0 ? 1 : 0;
         Application.LoadLevel("Map");
     },
                                   () =>
     {
         confirmModal   = null;
         Time.timeScale = Time.timeScale == 0 ? 1 : 0;
     });
 }