* Code cleaning
This commit is contained in:
jean.chalard
2009-09-03 17:23:26 +00:00
parent dd2a541c2b
commit 4e7b172846

View File

@@ -52,10 +52,7 @@ JQuad * Player::getIcon(){
Player * Player::opponent(){
GameObserver * game = GameObserver::GetInstance();
if (!game) return NULL;
for (int i= 0; i < 2; i++){
if (game->players[i] != this) return game->players[i];
}
return NULL;
return this == game->players[0] ? game->players[1] : game->players[0];
}
HumanPlayer::HumanPlayer(MTGPlayerCards * deck, string file, string fileSmall) : Player(deck, file, fileSmall) {