// Use this for initialization void Start() { Instance = this; //setting default value, if the game is played for the first time if (!PlayerPrefs.HasKey(SAVE_NAME)) { PlayerPrefs.SetString(SAVE_NAME, "0"); } //tells us if it's the first time that this game has been launched after install - 0 = no, 1 = yes if (!PlayerPrefs.HasKey("IsFirstTime")) { PlayerPrefs.SetInt("IsFirstTime", 1); } LoadLocal(); //we want to load local data first because loading from cloud can take quite a while, if user progresses while using local data, it will all //sync in our comparating loop in StringToGameData(string, string) //PlayGamesClientConfiguration config = new PlayGamesClientConfiguration.Builder() // .EnableSavedGames().Build(); // PlayGamesPlatform.InitializeInstance(config); // PlayGamesPlatform.Activate(); // SignIn(); }
// Use this for initialization void Start() { saveGame = GetComponent <scr_saveGame>(); StartCoroutine("StartScreen"); }