concede fix

This commit is contained in:
Max-Wilhelm Bruker
2011-03-09 15:46:33 +01:00
parent ac46edd790
commit 349a60fb58
2 changed files with 4 additions and 2 deletions

View File

@@ -512,6 +512,8 @@ ResponseCode Server_ProtocolHandler::cmdConcede(Command_Concede * /*cmd*/, Comma
{
if (player->getSpectator())
return RespFunctionNotAllowed;
if (!game->getGameStarted())
return RespGameNotStarted;
if (player->getConceded())
return RespContextError;
@@ -530,7 +532,7 @@ ResponseCode Server_ProtocolHandler::cmdReadyStart(Command_ReadyStart *cmd, Comm
if (player->getSpectator())
return RespFunctionNotAllowed;
if (!player->getDeck())
if (!player->getDeck() || game->getGameStarted())
return RespContextError;
if (player->getReadyStart() == cmd->getReady())