Пример #1
0
 private static void PrintOcean(Ocean oceanToPrint)
 {
     for (CoordX = 0; CoordX < 10; CoordX++)
     {
         Console.Write(" "
                       + oceanToPrint.ArrayOfSquares[CoordX, CoordY].Sign);
     }
 }
Пример #2
0
        public static void PrintBoard(Ocean ocean, Ocean secondOcean)

        {
            Console.WriteLine("    " + ocean.Name + space + space + space + secondOcean.Name);
            Console.ForegroundColor = ConsoleColor.Yellow;
            Console.WriteLine("   A  B  C  D  E  F  G  H  I  J"
                              + space
                              + "    A  B  C  D  E  F  G  H  I  J");
            Console.ResetColor();
            for (CoordY = 0; CoordY < 10; CoordY++)
            {
                PrintBoardLegendInYellow((CoordY + 1).ToString());
                PrintOcean(ocean);
                PrintBoardLegendInYellow(space + (CoordY + 1).ToString());
                PrintOcean(secondOcean);
                Console.WriteLine();
            }
            Console.Write("\n\n");
        }