mirror of
https://github.com/vcmi/vcmi.git
synced 2024-11-28 08:48:48 +02:00
Fixed shortage of Prisons on random maps.
This commit is contained in:
parent
9e5cc2d1b1
commit
cb5a3c0f73
@ -74,7 +74,7 @@ void CMapGenerator::initPrisonsRemaining()
|
||||
if (isAllowed)
|
||||
prisonsRemaining++;
|
||||
}
|
||||
prisonsRemaining = std::max<int> (0, prisonsRemaining - 16 * map->players.size()); //so at least 16 heroes will be available for every player
|
||||
prisonsRemaining = std::max<int> (0, prisonsRemaining - 16 * mapGenOptions->getPlayerCount()); //so at least 16 heroes will be available for every player
|
||||
}
|
||||
|
||||
std::unique_ptr<CMap> CMapGenerator::generate(CMapGenOptions * mapGenOptions, int randomSeed /*= std::time(nullptr)*/)
|
||||
|
Loading…
Reference in New Issue
Block a user