Example #1
0
        private void BtnClickJoin(object sender, RoutedEventArgs e)
        {
            if (!UsernameCheck() || !IpAddressCheck())
            {
                return;
            }

            Window window = new LobbyWindow(tbUsername.Text, tbAddress.Text);

            window.Show();
            this.Close();
        }
Example #2
0
        /// <summary>
        /// Open a lobby as a host.
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void BtnClickHost(object sender, RoutedEventArgs e)
        {
            if (!UsernameCheck())
            {
                return;
            }

            Window window = new LobbyWindow(tbUsername.Text);

            window.Show();
            this.Close();
        }