Do not rejoin games with 0 cash. Workaround for #108.

This commit is contained in:
lotodore
2012-01-28 11:50:33 +00:00
parent 33cdfdaed7
commit e658a18913
+1 -1
View File
@@ -2143,7 +2143,7 @@ ServerLobbyThread::GetRejoinGameIdForPlayer(const std::string &playerName, const
while (i != end) {
boost::shared_ptr<ServerGame> tmpGame = i->second;
boost::shared_ptr<PlayerInterface> tmpPlayer = tmpGame->GetPlayerInterfaceFromGame(playerName);
if (tmpPlayer && tmpPlayer->getMyGuid() == guid) {
if (tmpPlayer && tmpPlayer->getMyGuid() == guid && tmpPlayer->getMyCash() > 0) {
retGameId = tmpGame->GetId();
outPlayerUniqueId = tmpPlayer->getMyUniqueID();
break;