changeset 7748:21e8e4824ce1 draft

(svn r11285) -Fix: 'site unsuitable' was always shown instead specified message when trying to build industry ingame (Csaboka)
author glx <glx@openttd.org>
date Wed, 17 Oct 2007 15:47:49 +0000
parents 2f53bca4d8fb
children 999f65f6cdf6
files src/industry_cmd.cpp
diffstat 1 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/src/industry_cmd.cpp
+++ b/src/industry_cmd.cpp
@@ -1633,9 +1633,9 @@
 		num = indspec->num_table;
 		itt = indspec->table;
 
-
+		_error_message = STR_0239_SITE_UNSUITABLE;
 		do {
-			if (--num < 0) return_cmd_error(STR_0239_SITE_UNSUITABLE);
+			if (--num < 0) return CMD_ERROR;
 		} while (!CheckIfIndustryTilesAreFree(tile, itt[num], num, p1));
 
 		if (CreateNewIndustryHelper(tile, p1, flags, indspec, num) == NULL) return CMD_ERROR;