示例#1
0
 void DisconnectQuestion(MyGuiScreenMessageBoxCallbackEnum resultEnum)
 {
     if (resultEnum == MyGuiScreenMessageBoxCallbackEnum.YES)
     {
         OnCancelClick(null);
         MyGuiManager.BackToMainMenu();
     }
 }
示例#2
0
        protected void HandleSectorServiceError(Exception exception, MyMasterServiceClient client)
        {
            // abort connection (reconnect will restore connection after few seconds
            client.Abort();
            MyMwcLog.WriteLine(exception); // log exception

            // Show error dialog and go to main menu
            MyGuiManager.AddScreen(new MyGuiScreenMessageBox(MyMessageBoxType.ERROR, MyTextsWrapperEnum.PleaseTryAgain, MyTextsWrapperEnum.MessageBoxNetworkErrorCaption, MyTextsWrapperEnum.Ok, null));
            CloseScreen();
            MyGuiManager.BackToMainMenu();
        }
        public void OnCancelClick(MyGuiControlButton sender)
        {
            if (!MyGuiManager.IsMainMenuScreenOpened())
            {
                MyGuiScreenMainMenu.SkipAutologin();
                MyGuiManager.BackToMainMenu();
            }

            MyGuiManager.UpdateDemoAccessScreen();

            //  Just close the screen, ignore any change
            CloseScreen();
        }
示例#4
0
        public static void AfterLogos()
        {
            MyGuiManager.BackToMainMenu();

            if (MySteam.IsActive)
            {
                MyGuiScreenMainMenu.AddLoginScreenDrmFree((MyGuiScreenBase)null);
            }
            else
            {
                MyGuiScreenMainMenu.AddAutologinScreen();
            }
        }
示例#5
0
        protected override void OnError(Exception exception, MySectorServiceClient client)
        {
            MyMwcLog.WriteLine(exception); // log exception

            if (EnableRetry)
            {
                ShowRetryDialog(exception);
            }
            else
            {
                RaiseActionFailed(exception);
                if (ShowErrorMessage)
                {
                    MyGuiManager.AddScreen(new MyGuiScreenMessageBox(MyMessageBoxType.ERROR, ErrorMessageText, ErrorCaptionText, MyTextsWrapperEnum.Ok, null));
                }
                CloseScreen();
                if (OnErrorReturnToMainMenu)
                {
                    MyGuiManager.BackToMainMenu();
                }
            }
        }
 private void HandleNonexistentCheckpoint()
 {
     MyGuiManager.AddScreen(new MyGuiScreenMessageBox(MyMessageBoxType.ERROR, MyTextsWrapperEnum.TemplateCheckpointDeleted, MyTextsWrapperEnum.MessageBoxCaptionError, MyTextsWrapperEnum.Ok, null));
     CloseScreen();
     MyGuiManager.BackToMainMenu();
 }
示例#7
0
 private static void OnErrorClick(MyGuiScreenMessageBoxCallbackEnum result)
 {
     MyGuiManager.BackToMainMenu();
 }