void Awake() { if (_instance == null) { _instance = this; } }
void Awake() { if (PlayerPrefs.GetInt("HasHacked", 0) == 1) { privateCode = "F**K OFF"; publicCode = "F**K OFF"; PlayerPrefs.SetString("MyID", "000000000"); } highscoreDisplay = GetComponent <DisplayHighscores>(); instance = this; if (string.IsNullOrEmpty(PlayerPrefs.GetString("MyID"))) { myId = GenerateId(); PlayerPrefs.SetString("MyID", myId); } else { myId = PlayerPrefs.GetString("MyID"); } if (string.IsNullOrEmpty(PlayerPrefs.GetString("MyName"))) { myName = "NoName"; } else { myName = PlayerPrefs.GetString("MyName"); } print("ID: " + myId + " Name: " + myName); DownloadMyHighscore(); //MUSTBEDELETED(); }
void Awake() { instance = this; if (SceneManager.GetActiveScene().name == "LeaderboardScene") { displayHighscores = GetComponent <DisplayHighscores>(); } }
void Awake() { instance = this; instance.scene = SceneManager.GetActiveScene().name; if (instance.scene != "MainGame" && instance.scene != "Settings") { highscoreDisplay = GetComponent <DisplayHighscores>(); } if (instance.scene == "Settings") { scoreSheet = GetComponent <ScoreSheet>(); } }
private void Awake() { /*if (instance != null && instance != this) * { * Destroy(gameObject); * } * else * { * instance = this; * // DontDestroyOnLoad(gameObject); * }*/ instance = this; highscoresDisplay = GetComponent <DisplayHighscores>(); }
void Start() { nameText.text = PlayerPrefs.GetString("MyName"); masterMixer.GetFloat("musicVol", out normalMusicVol); masterMixer.GetFloat("soundVol", out normalSoundVol); displayHighscores = GetComponent <DisplayHighscores>(); ToggleMenu(isMenu); //Advanced Stuff displayHighscores.ToggleDisplay(string.IsNullOrEmpty(PlayerPrefs.GetString("MyName"))); CheckButtons(); LoadMenu(); CheckButtons(); }
void Awake() { highscoreDisplay = GetComponent <DisplayHighscores>(); instance = this; }
private void Awake() { instance = this; highscoresDisplay = GetComponent <DisplayHighscores>(); }
void Awake() { highscoresDisplay = GetComponent <DisplayHighscores>(); }
void Awake() { instance = this; highscoresDisplay = GetComponent<DisplayHighscores>(); }
void Awake() { Instance = this; displayHS = GetComponent <DisplayHighscores>(); }
// Start is called before the first frame update protected override void Awake() { this.IsPersistentBetweenScenes = false; highscoreDisplay = GetComponent <DisplayHighscores>(); base.Awake(); }
void Awake() { DownloadHighscores(); highscoreDisplay = GetComponent <DisplayHighscores>(); instance = this; }
private void Awake() { instance = this; }
void Awake() { highscoresDisplay = GetComponent<DisplayHighscores>(); }