private void Awake() { if (_instance != null) { Destroy(this.gameObject); } else { _instance = this; DontDestroyOnLoad(this.gameObject); } }
void Awake() { if (instance != null) { Destroy(this.gameObject); } else { instance = this; DontDestroyOnLoad(this.gameObject); win = PlayerPrefs.GetInt("Win", 0); lose = PlayerPrefs.GetInt("Lose", 0); tie = PlayerPrefs.GetInt("Tie", 0); ColorUtility.TryParseHtmlString(PlayerPrefs.GetString("PlayerColor", "#FFFFFF"), out playerColor); playerName = PlayerPrefs.GetString("PlayerName", "Player" + Random.Range(1, 1000)); } }
private void Start() { playDataManager = PlayDataManager.Instance; gpuMiningManager = GPUMiningManager.Instance; }
void Awake() { Instance = this; }
void Awake() { instance = this; }