private void Awake() { var progress = playerProfileManager.GetProgress(); SetupButton(level1Button, progress.levels, 0); SetupButton(level2Button, progress.levels, 1); SetupButton(level3Button, progress.levels, 2); }
void Start() { var progress = playrPlayerProfileManager.GetProgress(); if (progress.levels.Count <= levelNum) { return; } records = playrPlayerProfileManager.GetProgress().levels[levelNum].Ghost; if (records != null && records.Count > 0) { play = true; time = Time.time; ghost = Instantiate(ghostPrefab); } UpdatePosition(); }