diff options
author | belugas <belugas@openttd.org> | 2007-05-31 19:13:41 +0000 |
---|---|---|
committer | belugas <belugas@openttd.org> | 2007-05-31 19:13:41 +0000 |
commit | 4af692558a4e78e5b5b074f68adf3c60ff89d055 (patch) | |
tree | 539e6a1d877b0459ab303b47d86cf1ac9c8c1e2f /src/newgrf_house.cpp | |
parent | 01f80cf343918df3e9865cb272264ee3519154fa (diff) | |
download | openttd-4af692558a4e78e5b5b074f68adf3c60ff89d055.tar.xz |
(svn r10005) -Codechange: Merge two flags (2cc and newhouses) indicating some newgrf features have been loaded, and introduce the newindustry one.
Diffstat (limited to 'src/newgrf_house.cpp')
-rw-r--r-- | src/newgrf_house.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/newgrf_house.cpp b/src/newgrf_house.cpp index e6dd53df2..2883f9b2d 100644 --- a/src/newgrf_house.cpp +++ b/src/newgrf_house.cpp @@ -83,7 +83,7 @@ void IncreaseBuildingCount(Town *t, HouseID house_id) { HouseClassID class_id = GetHouseSpecs(house_id)->class_id; - if (!_have_newhouses) return; + if (!HASBIT(_loaded_newgrf_features, GRFLOADED_NEWHOUSES)) return; /* If there are 255 buildings of this type in this town, there are also * at least that many houses of the same class in the town, and @@ -111,7 +111,7 @@ void DecreaseBuildingCount(Town *t, HouseID house_id) { HouseClassID class_id = GetHouseSpecs(house_id)->class_id; - if (!_have_newhouses) return; + if (!HASBIT(_loaded_newgrf_features, GRFLOADED_NEWHOUSES)) return; if (t->building_counts.id_count[house_id] > 0) t->building_counts.id_count[house_id]--; if (_building_counts.id_count[house_id] > 0) _building_counts.id_count[house_id]--; @@ -129,7 +129,7 @@ void DecreaseBuildingCount(Town *t, HouseID house_id) */ void AfterLoadCountBuildings() { - if (!_have_newhouses) return; + if (!HASBIT(_loaded_newgrf_features, GRFLOADED_NEWHOUSES)) return; for (TileIndex t = 0; t < MapSize(); t++) { if (!IsTileType(t, MP_HOUSE)) continue; |