summaryrefslogtreecommitdiff
path: root/town_cmd.c
diff options
context:
space:
mode:
authorpasky <pasky@openttd.org>2005-03-17 23:12:23 +0000
committerpasky <pasky@openttd.org>2005-03-17 23:12:23 +0000
commitad579912f4be16f7333553d43e3712ea541c2350 (patch)
treeaaf4ba873d4614c178d027e80231afa6dc1f5320 /town_cmd.c
parentcb084f59c2fbd58d38b15cee53d563816fcbf1c7 (diff)
downloadopenttd-ad579912f4be16f7333553d43e3712ea541c2350.tar.xz
(svn r2021) Fix: Enlarge _cur_town_ctr from byte to uint32 so that all the towns are considered when growing them even for big maps, where much more than 256 towns are around; reported by Tomasz Dubiński <uboottd@hydra.polsl.gliwice.pl>. The savegame still saves just the lowest 8 bits but that doesn't hurt so much.
Diffstat (limited to 'town_cmd.c')
-rw-r--r--town_cmd.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/town_cmd.c b/town_cmd.c
index 7846d3fc0..718011396 100644
--- a/town_cmd.c
+++ b/town_cmd.c
@@ -442,7 +442,7 @@ void OnTick_Town(void)
for (counter += GetTownPoolSize();
counter >= TOWN_GROWTH_FREQUENCY;
counter -= TOWN_GROWTH_FREQUENCY) {
- int i = _cur_town_ctr;
+ uint32 i = _cur_town_ctr;
Town *t;
if (++_cur_town_ctr >= GetTownPoolSize())