Exemplo n.º 1
0
        public MainWindow()
        {
            this.InitializeComponent();
            banco = new BanCo(this, grdBanCo);
            BanCo.Option.WhoPlayWith = Player.MayOnline;
            banco.DrawGomokuBoard();
            grdBanCo.MouseDown += new System.Windows.Input.MouseButtonEventHandler(banco.grdBanCo_MouseDown);
            BanCo.WinEvent     += new BanCo.WinEventHander(banco_WinEvent);
            BanCo.LoseEvent    += new BanCo.LoseEventHander(banco_LoseEvent);

            txt.TextChanged         += new TextChangedEventHandler(txt_change);
            txtMay.TextChanged      += new TextChangedEventHandler(txtMay_Change);
            txtNguoiMay.TextChanged += new TextChangedEventHandler(txtNguoiMay_Change);
        }
Exemplo n.º 2
0
        public MainWindow()
        {
            this.InitializeComponent();
            banco = new BanCo(this, grdBanCo);
            BanCo.Option.WhoPlayWith = Player.MayOnline;
            banco.DrawGomokuBoard();
            grdBanCo.MouseDown += new System.Windows.Input.MouseButtonEventHandler(banco.grdBanCo_MouseDown);
            BanCo.WinEvent += new BanCo.WinEventHander(banco_WinEvent);
            BanCo.LoseEvent += new BanCo.LoseEventHander(banco_LoseEvent);

            txt.TextChanged += new TextChangedEventHandler(txt_change);
            txtMay.TextChanged += new TextChangedEventHandler(txtMay_Change);
            txtNguoiMay.TextChanged += new TextChangedEventHandler(txtNguoiMay_Change);
        }
Exemplo n.º 3
0
 public MainWindow()
 {
     this.InitializeComponent();
     banco = new BanCo(this, grdBanCo);
     BanCo.Option.WhoPlayWith = Player.MayOnline;
     banco.DrawGomokuBoard();
     grdBanCo.MouseDown += new System.Windows.Input.MouseButtonEventHandler(banco.grdBanCo_MouseDown);
     BanCo.WinEvent     += new BanCo.WinEventHander(banco_WinEvent);
     cbCheDo.Items.Add("Human vs Human");
     cbCheDo.Items.Add("Human vs AI");
     cbCheDo.Items.Add("Human vs Human Online");
     cbCheDo.Items.Add("Human vs AI online");
     cbCheDo.SelectedIndex    = 0;
     txt.TextChanged         += new TextChangedEventHandler(txt_change);
     txtMay.TextChanged      += new TextChangedEventHandler(txtMay_Change);
     txtNguoiMay.TextChanged += new TextChangedEventHandler(txtNguoiMay_Change);
     btnstart.IsEnabled       = false;
     btnSend.IsEnabled        = false;
 }
Exemplo n.º 4
0
        public MainWindow()
        {
            
            this.InitializeComponent();
            banco=new BanCo(this,grdBanCo);
            BanCo.Option.WhoPlayWith = Player.MayOnline;
			banco.DrawGomokuBoard();
            grdBanCo.MouseDown += new System.Windows.Input.MouseButtonEventHandler(banco.grdBanCo_MouseDown);
            BanCo.WinEvent += new BanCo.WinEventHander(banco_WinEvent);
            cbCheDo.Items.Add("Human vs Human");
            cbCheDo.Items.Add("Human vs AI");
            cbCheDo.Items.Add("Human vs Human Online");
            cbCheDo.Items.Add("Human vs AI online");
            cbCheDo.SelectedIndex = 0;
            txt.TextChanged += new TextChangedEventHandler(txt_change);
            txtMay.TextChanged += new TextChangedEventHandler(txtMay_Change);
            txtNguoiMay.TextChanged += new TextChangedEventHandler(txtNguoiMay_Change);
            btnstart.IsEnabled = false;
            btnSend.IsEnabled = false;
        }