diff options
author | smatz <smatz@openttd.org> | 2009-05-22 15:23:47 +0000 |
---|---|---|
committer | smatz <smatz@openttd.org> | 2009-05-22 15:23:47 +0000 |
commit | 10d1ef5447b94d17024dc0f4bdd1b7b017431a23 (patch) | |
tree | a9563d19933124547ccd3d6c0e53c44876bdc144 /src/town_cmd.cpp | |
parent | 62a7948af0ca9eb3b190a54918201e1075edcbbc (diff) | |
download | openttd-10d1ef5447b94d17024dc0f4bdd1b7b017431a23.tar.xz |
(svn r16379) -Codechange: remove GetNumTowns(), GetNumIndustries() and GetActiveCompanyCount(), use PoolItem::GetNumItems() instead
Diffstat (limited to 'src/town_cmd.cpp')
-rw-r--r-- | src/town_cmd.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/town_cmd.cpp b/src/town_cmd.cpp index a93de7620..825ef33f1 100644 --- a/src/town_cmd.cpp +++ b/src/town_cmd.cpp @@ -1760,7 +1760,7 @@ bool GenerateTowns(TownLayout layout) /* give it a last try, but now more aggressive */ if (num == 0 && CreateRandomTown(10000, TS_RANDOM, _settings_game.economy.larger_towns != 0, layout) == NULL) { - if (GetNumTowns() == 0) { + if (Town::GetNumItems() == 0) { if (_game_mode != GM_EDITOR) { extern StringID _switch_mode_errorstr; _switch_mode_errorstr = STR_COULD_NOT_CREATE_TOWN; @@ -2709,7 +2709,7 @@ Town *ClosestTownFromTile(TileIndex tile, uint threshold) if (tid == (TownID)INVALID_TOWN) { /* in the case we are generating "many random towns", this value may be INVALID_TOWN */ if (_generating_world) return CalcClosestTownFromTile(tile, threshold); - assert(GetNumTowns() == 0); + assert(Town::GetNumItems() == 0); return NULL; } |