mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-04-27 07:48:01 -07:00
preliminary AlwaysRevealTopCard support related to issue #31, server code cleanup (finally removed getGameState)
This commit is contained in:
parent
75bac4a5b9
commit
7417236c3a
28 changed files with 329 additions and 184 deletions
|
|
@ -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;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue