summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorfrosch <frosch@openttd.org>2012-04-26 21:03:34 +0000
committerfrosch <frosch@openttd.org>2012-04-26 21:03:34 +0000
commit0d03c1ff85e1b98fe1714d1bd0057869f345b21f (patch)
tree7c48b29faffc4a22fe4e2f5b60e99d7d85baf0a1
parentdbcc6bdcb47f2e8fe903e36bb75039a631182f14 (diff)
downloadopenttd-0d03c1ff85e1b98fe1714d1bd0057869f345b21f.tar.xz
(svn r24182) -Fix [FS#5169-ish]: The population of a town was computed incorrectly for overridden houses when loading a game.
-rw-r--r--src/saveload/town_sl.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/saveload/town_sl.cpp b/src/saveload/town_sl.cpp
index 6edd6ddd3..96cf87ada 100644
--- a/src/saveload/town_sl.cpp
+++ b/src/saveload/town_sl.cpp
@@ -35,7 +35,7 @@ void RebuildTownCaches()
for (TileIndex t = 0; t < MapSize(); t++) {
if (!IsTileType(t, MP_HOUSE)) continue;
- HouseID house_id = GetCleanHouseType(t);
+ HouseID house_id = GetHouseType(t);
town = Town::GetByTile(t);
IncreaseBuildingCount(town, house_id);
if (IsHouseCompleted(t)) town->cache.population += HouseSpec::Get(house_id)->population;