From 1e47593786e33fd4b06f79c354ae460ca61e4594 Mon Sep 17 00:00:00 2001 From: bjarni Date: Sat, 12 Aug 2006 10:41:29 +0000 Subject: (svn r5853) -Fix: [elrails] FS#178 Electric Trains can leave Conventional Depot now the user will get an error if he tries to start the train and the status bar will say "no power" instead of "stopped" Electric trains already driving in and out of non-electrified depots will still do so, but you can't start new ones --- train_gui.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'train_gui.c') diff --git a/train_gui.c b/train_gui.c index 1a3542a2a..376556071 100644 --- a/train_gui.c +++ b/train_gui.c @@ -954,7 +954,11 @@ static void TrainViewWndProc(Window *w, WindowEvent *e) str = STR_885C_BROKEN_DOWN; } else if (v->vehstatus & VS_STOPPED) { if (v->u.rail.last_speed == 0) { - str = STR_8861_STOPPED; + if (v->u.rail.cached_power == 0) { + str = STR_TRAIN_NO_POWER; + } else { + str = STR_8861_STOPPED; + } } else { SetDParam(0, v->u.rail.last_speed); str = STR_TRAIN_STOPPING + _patches.vehicle_speed; -- cgit v1.2.3-54-g00ecf