Exemplo n.º 1
0
        static void Main(string[] args)
        {
            //ゲームを作成
            Game    game    = new Game();
            IPlayer player1 = new AIPlayer2(StoneColor.Black);
            IPlayer player2 = new AIPlayer1(StoneColor.White);

            while (!game.HasEnd)
            {
                Console.WriteLine("");
                ShowBorad(game.Board);
                Console.WriteLine("");
                ShowNextPayer(player1, player2, game);
                int[] points = new int[2];
                points = NextPlayer(player1, player2, game).SelectPoint(game.Board);
                if (!game.PutStone(points[0], points[1], game.NextTurnColor))
                {
                    Console.WriteLine("その場所にはおけません");
                }
            }
            GameEnd(game);
        }
Exemplo n.º 2
0
        static void Main(string[] args)
        {
            //ゲームを作成
            Game game = new Game();
            IPlayer player1 = new AIPlayer2(StoneColor.Black);
            IPlayer player2 = new AIPlayer1(StoneColor.White);

            while (!game.HasEnd)
            {
                Console.WriteLine("");
                ShowBorad(game.Board);
                Console.WriteLine("");
                ShowNextPayer(player1, player2, game);
                int[] points = new int[2];
                points = NextPlayer(player1, player2, game).SelectPoint(game.Board);
                if (!game.PutStone(points[0], points[1], game.NextTurnColor))
                {
                    Console.WriteLine("その場所にはおけません");
                }
            }
              GameEnd(game);
        }