summaryrefslogtreecommitdiff
path: root/industry_cmd.c
diff options
context:
space:
mode:
authormiham <miham@openttd.org>2005-01-09 14:07:59 +0000
committermiham <miham@openttd.org>2005-01-09 14:07:59 +0000
commit3ef2e81c69b9a2a7a62060bb07f4fa30831a38b1 (patch)
tree24561354552f7c4d789cdb6fd78f1f735eacdeb1 /industry_cmd.c
parente0a8b214040d02d01e30306437698f6368be7721 (diff)
downloadopenttd-3ef2e81c69b9a2a7a62060bb07f4fa30831a38b1.tar.xz
(svn r1443) Added feature that users are able to place multiple accepting industies nearby in the editor mode if the appropriate patches are set
Diffstat (limited to 'industry_cmd.c')
-rw-r--r--industry_cmd.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/industry_cmd.c b/industry_cmd.c
index 498958bfc..e8b00a8b7 100644
--- a/industry_cmd.c
+++ b/industry_cmd.c
@@ -1376,7 +1376,10 @@ static bool CheckIfTooCloseToIndustry(uint tile, int type)
if (i->xy != 0 &&
(GetTileDist1D(tile, i->xy) <= 14) &&
spec->accepts_cargo[0] != 0xFF &&
- spec->accepts_cargo[0] == i->accepts_cargo[0]) {
+ spec->accepts_cargo[0] == i->accepts_cargo[0] &&
+ !(_game_mode == GM_EDITOR &&
+ _patches.same_industry_close &&
+ _patches.multiple_industry_per_town)) {
_error_message = STR_INDUSTRY_TOO_CLOSE;
return false;
}