public void LoadSaveGameData() { var saveData = SaveGameSerializer.Load(); var highScoresManager = GetComponent <HighScoresManager>(); if (highScoresManager != null) { highScoresManager.LoadHighScores(saveData); } }
public void SaveGameData() { var saveData = SaveGameSerializer.Load(); var highScoresManager = GetComponent <HighScoresManager>(); if (highScoresManager != null) { saveData.highScores = highScoresManager.highScores; } SaveGameSerializer.Save(saveData); }