diff options
author | smatz <smatz@openttd.org> | 2008-12-26 19:37:50 +0000 |
---|---|---|
committer | smatz <smatz@openttd.org> | 2008-12-26 19:37:50 +0000 |
commit | 7fbd5beb0f92c6f53b4b8d9206773003328b2e7d (patch) | |
tree | d4bd34c6215ede747794b7a5273d6a5c6d3390c8 /src/industry_cmd.cpp | |
parent | 047e40d33ff1b5b0d407dda7e73d34430e268494 (diff) | |
download | openttd-7fbd5beb0f92c6f53b4b8d9206773003328b2e7d.tar.xz |
(svn r14746) -Fix: don't let any disaster vehicle (Helicopter or Airplane) target invalid industry
Diffstat (limited to 'src/industry_cmd.cpp')
-rw-r--r-- | src/industry_cmd.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/industry_cmd.cpp b/src/industry_cmd.cpp index a9a837dbe..543c21654 100644 --- a/src/industry_cmd.cpp +++ b/src/industry_cmd.cpp @@ -166,6 +166,9 @@ Industry::~Industry() } END_TILE_LOOP(tile_cur, 42, 42, this->xy - TileDiff(21, 21)) } + /* don't let any disaster vehicle target invalid industry */ + ReleaseDisastersTargetingIndustry(this->index); + DecIndustryTypeCount(this->type); DeleteSubsidyWithIndustry(this->index); |