public void Awake() { PopulateHighscore populateHighscore = menu.GetComponentInChildren <PopulateHighscore>(); populateHighscore.NewGrid(); populateHighscore.PopulateTotal(); }
public void SetMenuActive(GameObject menu) { if (menu.activeInHierarchy == false) { menu.SetActive(true); } if (menu == optionsMenu) { List <string> options = optManager.BuildResolutionsList(); resolutionDrop.ClearOptions(); resolutionDrop.AddOptions(options); resolutionDrop.value = optManager.currentResIndex; resolutionDrop.RefreshShownValue(); soundSlider.value = PlayerPrefsManager.GetSfxVolume(); musicSlider.value = PlayerPrefsManager.GetMusicVolume(); } else if (menu == highscoreMenu) { PopulateHighscore populateHighscore = menu.GetComponentInChildren <PopulateHighscore>(); populateHighscore.NewGrid(); populateHighscore.PopulateTotal(); } }