summaryrefslogtreecommitdiff
path: root/main_gui.c
diff options
context:
space:
mode:
authorbelugas <belugas@openttd.org>2006-10-24 19:19:25 +0000
committerbelugas <belugas@openttd.org>2006-10-24 19:19:25 +0000
commitf48c419467197418d1f2b426cfcf1ee3e1bf554b (patch)
tree6c16ace129716db3f73132dc8d0bbbee789f4810 /main_gui.c
parentacbdd24f2f8a752933ba6fd331e6ec4c160027e9 (diff)
downloadopenttd-f48c419467197418d1f2b426cfcf1ee3e1bf554b.tar.xz
(svn r6930) -Codechange: Move industry name into IndustrySpec
-Codechange: member color_map is more related to random color, rename it as such
Diffstat (limited to 'main_gui.c')
-rw-r--r--main_gui.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/main_gui.c b/main_gui.c
index 128a48bf0..022e9a49a 100644
--- a/main_gui.c
+++ b/main_gui.c
@@ -39,6 +39,7 @@
#include "network_client.h"
#include "network_server.h"
#include "network_gui.h"
+#include "industry.h"
static int _rename_id;
static int _rename_what;
@@ -1665,7 +1666,7 @@ static void ScenEditIndustryWndProc(Window *w, WindowEvent *e)
// Show error if no town exists at all
type = _industry_type_to_place;
if (!AnyTownExists()) {
- SetDParam(0, type + STR_4802_COAL_MINE);
+ SetDParam(0, GetIndustrySpec(type)->name);
ShowErrorMessage(STR_0286_MUST_BUILD_TOWN_FIRST, STR_0285_CAN_T_BUILD_HERE, e->we.place.pt.x, e->we.place.pt.y);
return;
}
@@ -1674,7 +1675,7 @@ static void ScenEditIndustryWndProc(Window *w, WindowEvent *e)
_generating_world = true;
_ignore_restrictions = true;
if (!TryBuildIndustry(e->we.place.tile,type)) {
- SetDParam(0, type + STR_4802_COAL_MINE);
+ SetDParam(0, GetIndustrySpec(type)->name);
ShowErrorMessage(_error_message, STR_0285_CAN_T_BUILD_HERE, e->we.place.pt.x, e->we.place.pt.y);
}
_ignore_restrictions = false;