// display the level details void UpdateLevelDetails() { string levelName = Maps.maps[currentLevelIndex]; levelNameText.text = levelName; LevelPreview.LoadPreview(levelName, preview); }
// Load in the details of the current recording void UpdateRecordingDetails() { if (recordingsExist) { HideMessage(); string levelName = recordings [currentRecordingIndex]; levelNameText.text = levelName; LevelPreview.LoadPreview(levelName, preview); } else { DisplayMessage("No recordings found.\n\nPlay a game and\nsave a recording."); } }
void DisplayNames(Score[] scores) { // update level name as well levelNameText.text = currentLevelName; // update level preview LevelPreview.LoadPreview(currentLevelName, preview); // update score list for (int i = 0; i < items.Length; i++) { LeaderboardItem item = items[i]; item.player1 = scores[i].player1; item.player2 = scores[i].player2; item.score = scores[i].time.ToString(); } // make sure score list is currently displayed scoresList.SetActive(true); messageText.SetActive(false); }