Exemplo n.º 1
0
        public void WaitForAnotherPlayer()
        {
            //  this.vm.VM_start();
            //   this.Dispatcher.BeginInvoke(System.Windows.Threading.DispatcherPriority.Normal, new Action(() =>
            //     {
            this.vm.VM_start();
            MultiPlayerMazeWindow win = new MultiPlayerMazeWindow(" start");

            win.Show();
            this.Close();
            // }));
        }
Exemplo n.º 2
0
 private void JoinGameButton_Click(object sender, RoutedEventArgs e)
 {
     try
     {
         this.vm.VM_NameOfMaze = (string)comboBox.SelectedItem;
         this.vm.VM_join();
         MultiPlayerMazeWindow win = new MultiPlayerMazeWindow(" Join");
         win.Show();
         this.Close();
     }
     catch (Exception)
     {
         Message.ShowOKMessage("we are sorry, there is a problem with the connection, please try again later..", "ERROE");
     }
 }