preliminary AlwaysRevealTopCard support related to issue #31, server code cleanup (finally removed getGameState)

This commit is contained in:
Max-Wilhelm Bruker
2012-03-31 21:47:30 +02:00
parent 75bac4a5b9
commit 7417236c3a
28 changed files with 329 additions and 184 deletions

View File

@@ -70,7 +70,7 @@ void Server_ProtocolHandler::prepareDestroy()
continue;
}
g->gameMutex.lock();
Server_Player *p = g->getPlayer(gameIterator.value().second);
Server_Player *p = g->getPlayers().value(gameIterator.value().second);
if (!p) {
g->gameMutex.unlock();
r->gamesMutex.unlock();
@@ -220,7 +220,7 @@ Response::ResponseCode Server_ProtocolHandler::processGameCommandContainer(const
}
QMutexLocker gameLocker(&game->gameMutex);
Server_Player *player = game->getPlayer(roomIdAndPlayerId.second);
Server_Player *player = game->getPlayers().value(roomIdAndPlayerId.second);
if (!player)
return Response::RespNotInRoom;