Esempio n. 1
0
        public void DrawPlayerWin()
        {
            Logic.Connect4Colour player = Program.GameLogic.CurrPlayerColour;
            string message = $"Player {player.ColourName} won!";

            DrawColouredString((int)((Program.WindowWidth / 2) - Math.Round((float)(message.Length / 2))), Program.WindowHeight / 2, message, player.Colour);
        }
Esempio n. 2
0
        public void DrawPlayerTurn()
        {
            Logic.Connect4Colour player = Program.GameLogic.CurrPlayerColour;
            //Spaces save me having to erase previous player turn text
            string message = $"          {player.ColourName}'s turn          ";

            DrawColouredString((int)((Program.WindowWidth / 2) - Math.Round((float)(message.Length / 2))), Program.WindowHeight - 4, message, player.Colour);
        }
Esempio n. 3
0
        public void DrawConnectFourDot(int gridX, int gridY, Logic.Connect4Colour colour)
        {
            ConsoleColor prevColour = Console.ForegroundColor;

            Console.ForegroundColor = colour.Colour;
            DrawChar(gridX + ConnectFourGridStartX, gridY + ConnectFourGridStartY, 'O');

            Console.ForegroundColor = prevColour;
        }