Commits

trikitrok  committed e7fb48c Draft

Renamed some parameters and eliminated unnecessay check

  • Participants
  • Parent commits 8172bf8

Comments (0)

Files changed (2)

File src/Game.cpp

 	delete state;
 }
 
-void Game::pointTo(Player * player)
+void Game::pointTo(Player * pointWinner)
 {
-	if(not isOver())
-	{
-		player->winPoint();
-
-		updateState(player);
-	}
+	pointWinner->winPoint();
+	updateState(pointWinner);
 }
 
 void Game::updateState(Player * pointWinner)
 		Game(Player * player1, Player * player2);
 		virtual ~Game();
 
-		void pointTo(Player * player);
+		void pointTo(Player * pointWinner);
 
 		std::string score() const;
 
 
 		GameState * state;
 
-		void updateState(Player * player);
+		void updateState(Player * pointWinner);
 };
 
 #endif /* GAME_H_ */