예제 #1
0
    public void Awake()
    {
        Debug.Log("Initializing a new GUIManager.");

        // Cada nuevo GUI manager destruye el anterior para facilitar la creación de modos nuevos
        instance = this;

        GoBackButton.SetActive(false);
        RandomCard.SetActive(false);
        OpenConfigMenuButton.SetActive(true);
        GeneralConfMenu.SetActive(false);
        ConfLang.SetActive(false);
        ConfTypeSentences.SetActive(false);
        ConfNivelPicante.SetActive(false);
        ConfCustomSentences.SetActive(false);
        ConfPlayers.SetActive(false);
        WarningPopup.SetActive(false);
        InfoPopup.SetActive(false);
        LinkPopup.SetActive(false);
        ConditionPopup.SetActive(false);
        ConfMiscelanea.SetActive(false);
        rateAppPopup.SetActive(false);

        Debug.Log("GUIManager initialization successful.");
    }
예제 #2
0
    public void OpenConfigurationPanel(configurationPanels panel)
    {
        switch (panel)
        {
        case configurationPanels.GeneralConfMenu: GeneralConfMenu.SetActive(true); break;

        case configurationPanels.ConfLang: ConfLang.SetActive(true); break;

        case configurationPanels.ConfTypeSentences: ConfTypeSentences.SetActive(true); break;

        case configurationPanels.ConfNivelPicante: ConfNivelPicante.SetActive(true); break;

        case configurationPanels.ConfCustomSentences: ConfCustomSentences.SetActive(true); break;

        case configurationPanels.ConfPlayers: ConfPlayers.SetActive(true); break;

        case configurationPanels.ConfMiscelanea: ConfMiscelanea.SetActive(true); break;

        default: Debug.LogError("Unnexpected panel to be opened"); break;
        }
    }