1
0
mirror of https://github.com/vcmi/vcmi.git synced 2024-11-21 17:17:06 +02:00

Fix crash on starting random map with random number of players

This commit is contained in:
Ivan Savenko 2024-05-17 18:25:09 +00:00
parent 194b3389f9
commit 004e6d1fcb
2 changed files with 2 additions and 2 deletions

View File

@ -10,7 +10,7 @@ android {
applicationId "is.xyz.vcmi"
minSdk 19
targetSdk 33
versionCode 1513
versionCode 1514
versionName "1.5.1"
setProperty("archivesBaseName", "vcmi")
}

View File

@ -986,7 +986,7 @@ void CVCMIServer::multiplayerWelcomeMessage()
{
int humanPlayer = 0;
for (auto & pi : si->playerInfos)
if(gh->getPlayerState(pi.first)->isHuman())
if(pi.second.isControlledByHuman())
humanPlayer++;
if(humanPlayer < 2) // Singleplayer