Esempio n. 1
0
File: Mains.cs Progetto: iodz37/Iodz
 private static bool ConquordConsole_CloseEvent(CtrlType sig)
 {
     if (MessageBox.Show("Do You Want To Close Console ...?", "Message", MessageBoxButtons.OKCancel, MessageBoxIcon.Question) == DialogResult.OK)
     {
         Save();
         foreach (Client.GameClient client in Kernel.GamePool.Values)
         {
             client.Disconnect();
         }
         GameServer.Disable();
         AuthServer.Disable();
         if (GuildWar.IsWar)
         {
             GuildWar.End();
         }
         if (EliteGuildWar.IsWar)
         {
             EliteGuildWar.End();
         }
         if (ClanWar.IsWar)
         {
             ClanWar.End();
         }
         if (CaptureTheFlag.IsWar)
         {
             CaptureTheFlag.Close();
         }
         Application.Exit();
         Environment.Exit(0);
         return(false);
     }
     else
     {
         return(true);
     }
 }