예제 #1
0
    public void Awake()
    {
        PopulateHighscore populateHighscore = menu.GetComponentInChildren <PopulateHighscore>();

        populateHighscore.NewGrid();
        populateHighscore.PopulateTotal();
    }
예제 #2
0
    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();
        }
    }