Пример #1
0
 private void okButton_Click(object sender, EventArgs e)
 {
     m_selectedPlayer = (String)playerListBox.SelectedItem;
     if (m_selectedPlayer == null)
     {
         MessageBox.Show("Must select a player.");
         return;
     }
     m_serverConnection.SetLocalPlayer(m_selectedPlayer);
 }
Пример #2
0
        public bool initialize()
        {
            if (!_connection.ConnectToServer(_hostname, _port))
            {
                MessageBox.Show(this, "Connection to server failed; Exiting...");
                return(false);
            }
            _connection.ReadSimModel(String.Format("\\\\{0}\\DDDClient\\SimulationModel.xml", _hostname));
            _connection.SetLocalPlayer(_actingDMName);
            // _connection.LoginPlayer(_actingDMName, "OBSERVER");
            this.Text = String.Format("QA Test Form (Connected to {0}:{1})", _hostname, _port);
            this.toolStripStatusLabelServerStatus.Text = "CONNECTED";

            return(true);
        }