1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-01-18 03:21:27 +02:00

Randomly shuffle required objects to avoid patterns

This commit is contained in:
nordsoft 2022-08-31 01:03:35 +04:00 committed by Andrii Danylchenko
parent 47d3539f41
commit be6a7d1836

View File

@ -27,7 +27,7 @@
void ObjectManager::process()
{
zone.fractalize();
createRequiredObjects();
createRequiredObjects();
}
void ObjectManager::init()
@ -220,6 +220,7 @@ bool ObjectManager::createRequiredObjects()
{
logGlobal->trace("Creating required objects");
RandomGeneratorUtil::randomShuffle(requiredObjects, generator.rand);
for(const auto & object : requiredObjects)
{
auto * obj = object.first;