private void LateUpdate()
    {
        if (!(null != m_guimaster) || !m_guiParent.activeSelf)
        {
            return;
        }
        string clickedButtonName = m_guimaster.GetClickedButtonName();

        if (!(string.Empty != clickedButtonName))
        {
            return;
        }
        if ("btn_quit_yes" == clickedButtonName)
        {
            if (!IsBattleLogging())
            {
                TheOneAndOnly theOneAndOnly = (TheOneAndOnly)Object.FindObjectOfType(typeof(TheOneAndOnly));
                Object.DestroyImmediate(theOneAndOnly.gameObject);
                Application.LoadLevel(0);
            }
        }
        else if ("btn_quit_no" == clickedButtonName)
        {
            ShowGui(false);
        }
    }
Beispiel #2
0
 private void LateUpdate()
 {
     if (null != this.m_guimaster && this.m_guiParent.activeSelf)
     {
         string clickedButtonName = this.m_guimaster.GetClickedButtonName();
         if (string.Empty != clickedButtonName)
         {
             if ("btn_quit_yes" == clickedButtonName)
             {
                 if (!this.IsBattleLogging())
                 {
                     TheOneAndOnly theOneAndOnly = (TheOneAndOnly)UnityEngine.Object.FindObjectOfType(typeof(TheOneAndOnly));
                     UnityEngine.Object.DestroyImmediate(theOneAndOnly.gameObject);
                     Application.LoadLevel(0);
                 }
             }
             else if ("btn_quit_no" == clickedButtonName)
             {
                 this.ShowGui(false);
             }
         }
     }
 }