Exemplo n.º 1
0
        void ShareRecord()
        {
            string name = user.first_name;

            if (user.username != null)
            {
                name = user.username;
            }
            ServerMethods.sendBroadMessage("The user " + name + " just answered a message in " + response.Min().ToString("#.000") + " seconds!");
        }
Exemplo n.º 2
0
        public static void Main(string[] args)
        {
            localUsersData.LoadData();
            localUsersData.DeleteOld();

            if (ServerMethods.GetMe().ok)
            {
                new Thread(Updater).Start();
                ServerMethods.sendBroadMessage("I am back on\n<b>MV</b>", true);
            }
        }
Exemplo n.º 3
0
        public static void Main(string[] args)
        {
            /*
             * Thread formThread = new Thread(RunForm);
             * formThread.Name = "Form Thread";
             * formThread.Start();
             * formCreated.WaitOne();
             * formCreated = null; //this is not supposed to be used anymore
             */

            localUsersData.LoadData();
            localUsersData.DeleteOld();

            if (ServerMethods.GetMe().ok)
            {
                new Thread(Updater).Start();
                ServerMethods.sendBroadMessage("I am back on\n<b>MV</b>", true);
            }
        }
Exemplo n.º 4
0
 /*
  * static void RunForm() {
  *  form = new Form(formCreated);
  *  try {
  *             Application.Run(form);
  *  } catch ( Exception exception ) {
  *      File.AppendAllLines(localUsersData.LogFilepath, exception.ToString().Split(new string[] { "\n" }, StringSplitOptions.None).ToArray());
  *      throw;
  *  }
  *  //code after Application.Run is not executed!
  * }
  */
 public static void Close(object sender, FormClosingEventArgs e)
 {
     ServerMethods.sendBroadMessage("I will be off for a while\n<b>MV</b>", true);
     localUsersData.SaveData();
     Environment.Exit(0);
 }