1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-07-05 00:49:09 +02:00

Merge pull request #1848 from Nordsoft91/editor-fix

Fix map editor crash with cutting random town
This commit is contained in:
Ivan Savenko
2023-04-02 20:09:24 +03:00
committed by GitHub

View File

@ -256,6 +256,8 @@ public:
h & townAndVis;
BONUS_TREE_DESERIALIZATION_FIX
if(town)
{
vstd::erase_if(builtBuildings, [this](BuildingID building) -> bool
{
if(!town->buildings.count(building) || !town->buildings.at(building))
@ -265,6 +267,7 @@ public:
}
return false;
});
}
h & overriddenBuildings;