diff options
Diffstat (limited to 'tunnelbridge_cmd.c')
-rw-r--r-- | tunnelbridge_cmd.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/tunnelbridge_cmd.c b/tunnelbridge_cmd.c index 17b803628..a1db8f866 100644 --- a/tunnelbridge_cmd.c +++ b/tunnelbridge_cmd.c @@ -772,6 +772,9 @@ int32 DoConvertTunnelBridgeRail(TileIndex tile, RailType totype, bool exec) if (GetRailType(tile) == totype) return CMD_ERROR; + // 'hidden' elrails can't be downgraded to normal rail when elrails are disabled + if (_patches.disable_elrails && totype == RAILTYPE_RAIL && GetRailType(tile) == RAILTYPE_ELECTRIC) return CMD_ERROR; + endtile = CheckTunnelBusy(tile, &length); if (endtile == INVALID_TILE) return CMD_ERROR; |