예제 #1
0
파일: AI.cs 프로젝트: zhc0757/FiveInARow
 private async void Chessboard_ChessPiecePlaced(object sender, ChessPiecePlacedEventArgs e)
 {
     if (e.IsWin)
     {
         await StopThinking();
     }
 }
예제 #2
0
        private void Chessboard_ChessPiecePlaced(object sender, ChessPiecePlacedEventArgs e)
        {
            this.Dispatcher.Invoke(() =>
            {
                setChessPiece(e.ChessPiece);
            });

            if (e.IsWin)
            {
                MessageBox.Show("Win!");
            }
        }