summaryrefslogtreecommitdiff
path: root/oldloader.c
diff options
context:
space:
mode:
authortruelight <truelight@openttd.org>2005-02-02 17:30:29 +0000
committertruelight <truelight@openttd.org>2005-02-02 17:30:29 +0000
commit83a889d6787dbb5899c8eec663634d36fb1c8108 (patch)
treef37dce29ebc098007022941531aab37cff480e31 /oldloader.c
parentab3ed5c43121cc8adefc0c6bbcf9ef0d1203d3ff (diff)
downloadopenttd-83a889d6787dbb5899c8eec663634d36fb1c8108.tar.xz
(svn r1771) -Add: Industries are now dynamic (up to 64k industries). Generating
1kx1k maps should now be much faster, and give more than just oil-stuff ;)
Diffstat (limited to 'oldloader.c')
-rw-r--r--oldloader.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/oldloader.c b/oldloader.c
index 1b8bca9c2..6de0c483e 100644
--- a/oldloader.c
+++ b/oldloader.c
@@ -647,6 +647,9 @@ static void FixIndustry(OldIndustry *o, int num)
if (o->xy == 0)
continue;
+ if (!AddBlockIfNeeded(&_industry_pool, j))
+ error("Industries: failed loading savegame: too many industries");
+
i = GetIndustry(j);
i->xy = o->xy;