예제 #1
0
        public static void ShowCapturedPieces(ChessParty party)
        {
            Console.WriteLine("Captured Pieces: ");
            Console.WriteLine("Whites: ");
            ShowGroupofPieces(party.capturedPieces(Color.White));
            Console.WriteLine();
            Console.WriteLine("Blacks: ");
            ConsoleColor aux = Console.ForegroundColor;

            Console.ForegroundColor = ConsoleColor.Yellow;
            ShowGroupofPieces(party.capturedPieces(Color.Black));
            Console.ForegroundColor = aux;
            Console.WriteLine();
        }
예제 #2
0
 public static void ShowTheGame(ChessParty party)
 {
     ShowTheBattleField(party.Bat);
     Console.WriteLine();
     ShowCapturedPieces(party);
     Console.WriteLine();
     Console.WriteLine("Round: " + party.Round);
     if (!party.Finished)
     {
         Console.WriteLine("Waiting a Movement: " + party.CurrentPlayer);
         if (party.Check)
         {
             Console.WriteLine("Check.");
         }
     }
     else
     {
         Console.WriteLine("CheckMate.");
         Console.WriteLine("Winner: " + party.CurrentPlayer);
     }
 }
예제 #3
0
 public Pawn(BattleField Bat, Color color, ChessParty chessParty) : base(Bat, color)
 {
     this.chessParty = chessParty;
 }