commit 3db111deffcd5ec767f81682f9f9c2106e05b69a
parent 3fa6bf48a50a767df56115bc26a857ee4ac13718
Author: Martin Kloeckner <mjkloeckner@gmail.com>
Date: Mon, 1 Apr 2024 00:07:46 -0300
Change Win message
Diffstat:
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/guias/2/ej12.cpp b/guias/2/ej12.cpp
@@ -67,13 +67,14 @@ void game_player_status_msg() {
player_status = std::string("Player ");
current_player_string << current_player+1;
player_status += current_player_string.str();
+ player_status += "\033[0J";
}
else if (game_status == WIN) {
unsigned int player_won = ((current_player == PLAYER_1) ? PLAYER_2 : PLAYER_1);
player_status = std::string("Player ");
current_player_string << player_won+1;
player_status += current_player_string.str();
- player_status += " Wins!!";
+ player_status += " Wins";
game_status = HALT;
}
else if (game_status == DRAFT) {