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

        populateHighscore.NewGrid();
        populateHighscore.PopulateTotal();
    }
Exemple #2
0
 private void Awake()
 {
     inputManager        = FindObjectOfType <PW_InputManager>();
     localizationManager = FindObjectOfType <LocalizationManager>();
     highscoreHandler    = FindObjectOfType <HighscoreHandler>();
     populateHighscore   = GetComponentInChildren <PopulateHighscore>(true);
 }
Exemple #3
0
 public void BuildLevelEndMenu()
 {
     if (TournamentTracker.IsTournamentRunning())
     {
         endOfGameMenu_T.SetActive(true);
         populateHighscore = endOfGameMenu_T.GetComponentInChildren <PopulateHighscore>();
         scoreTextObject_T.GetComponent <TMP_Text>().text = highscoreHandler.GetHighscoreText();
     }
     else
     {
         endOfGameMenu.SetActive(true);
         populateHighscore = endOfGameMenu.GetComponentInChildren <PopulateHighscore>();
         scoreTextObject.GetComponent <TMP_Text>().text = highscoreHandler.GetHighscoreText();
     }
     populateHighscore.NewGrid();
     populateHighscore.NewLevelScore(SceneHandler.GetSceneName());
 }
Exemple #4
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();
        }
    }