Beispiel #1
0
 /// <summary>
 /// Signals our operation has completed with optional reason
 /// </summary>
 public virtual void OnOperationCompleted(bool result, string reason)
 {
     if (OperationCompleted != null)
     {
         OperationCompletedEvent ope = new OperationCompletedEvent(result);
         ope.Reason = (String.IsNullOrEmpty(reason) ? "" : reason);
         OperationCompleted(this, ope);
     }
 }
Beispiel #2
0
 /// <summary>
 /// Our internal account server connection attempt event.
 /// </summary>
 void ConnectAccountServer(object sender, OperationCompletedEvent e)
 {
     //Since this was fired, check connection
     if (e.Result)
     {
         //True = connected approved
         Screens.LoadingScreen.Load(false, new ZoneListScreen());
     }
     else
     {
         //Denied, show reason
         ScreenManager.AddScreen(new MessageBox(e.Reason, true));
         Busy.ExitScreen();
     }
 }
Beispiel #3
0
 /// <summary>
 /// Our internal zone server connection attempt event.
 /// </summary>
 void ConnectZoneServer(object sender, OperationCompletedEvent e)
 {
     //Since this was fired, check connection
     if (e.Result)
     {
         //True = connection approved
         //Set up our message display first then load
         LoadingScreen.Load(true, new GameScreen());
     }
     else
     {
         //Denied, show reason
         ScreenManager.AddScreen(new MessageBox(e.Reason, true));
         Busy.ExitScreen();
     }
 }