From c10d3da133d2c9084edffbea0a431f49813af763 Mon Sep 17 00:00:00 2001 From: smatz Date: Thu, 27 Dec 2007 14:10:47 +0000 Subject: (svn r11707) -Fix: do not allow refitting flooded (destroyed) vehicles --- src/roadveh_cmd.cpp | 1 + 1 file changed, 1 insertion(+) (limited to 'src/roadveh_cmd.cpp') diff --git a/src/roadveh_cmd.cpp b/src/roadveh_cmd.cpp index 772f5fba0..83e6f7c42 100644 --- a/src/roadveh_cmd.cpp +++ b/src/roadveh_cmd.cpp @@ -2134,6 +2134,7 @@ CommandCost CmdRefitRoadVeh(TileIndex tile, uint32 flags, uint32 p1, uint32 p2) if (v->type != VEH_ROAD || !CheckOwnership(v->owner)) return CMD_ERROR; if (!CheckRoadVehInDepotStopped(v)) return_cmd_error(STR_9013_MUST_BE_STOPPED_INSIDE); + if (v->vehstatus & VS_CRASHED) return_cmd_error(STR_CAN_T_REFIT_DESTROYED_VEHICLE); if (new_cid >= NUM_CARGO) return CMD_ERROR; -- cgit v1.2.3-54-g00ecf