Merge branch 'improved_breakdowns' into jgrpp

# Conflicts:
#	src/vehiclelist.cpp
This commit is contained in:
Jonathan G Rennison
2017-08-15 19:26:26 +01:00
60 changed files with 261 additions and 143 deletions

View File

@@ -872,7 +872,8 @@ CommandCost CmdInsertOrder(TileIndex tile, DoCommandFlag flags, uint32 p1, uint3
case OSL_PLATFORM_NEAR_END:
case OSL_PLATFORM_MIDDLE:
if (v->type != VEH_TRAIN) return CMD_ERROR;
/* FALL THROUGH */
FALLTHROUGH;
case OSL_PLATFORM_FAR_END:
break;
@@ -992,7 +993,8 @@ CommandCost CmdInsertOrder(TileIndex tile, DoCommandFlag flags, uint32 p1, uint3
case OCV_LOAD_PERCENTAGE:
case OCV_RELIABILITY:
if (new_order.GetConditionValue() > 100) return CMD_ERROR;
/* FALL THROUGH */
FALLTHROUGH;
default:
if (occ == OCC_IS_TRUE || occ == OCC_IS_FALSE) return CMD_ERROR;
break;
@@ -1651,7 +1653,8 @@ CommandCost CmdModifyOrder(TileIndex tile, DoCommandFlag flags, uint32 p1, uint3
case OCV_LOAD_PERCENTAGE:
case OCV_RELIABILITY:
if (order->GetConditionValue() > 100) order->SetConditionValue(100);
/* FALL THROUGH */
FALLTHROUGH;
default:
if (old_var_was_cargo) order->SetConditionValue(0);
if (occ == OCC_IS_TRUE || occ == OCC_IS_FALSE) order->SetConditionComparator(OCC_EQUALS);