summaryrefslogtreecommitdiff
path: root/src/order_cmd.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/order_cmd.cpp')
-rw-r--r--src/order_cmd.cpp14
1 files changed, 5 insertions, 9 deletions
diff --git a/src/order_cmd.cpp b/src/order_cmd.cpp
index b792c9beb..d02522cc6 100644
--- a/src/order_cmd.cpp
+++ b/src/order_cmd.cpp
@@ -115,15 +115,11 @@ bool Order::Equals(const Order &other) const
if ((this->IsType(OT_GOTO_DEPOT) && this->type == other.type) &&
((this->GetDepotActionType() & ODATFB_NEAREST_DEPOT) != 0 ||
(other.GetDepotActionType() & ODATFB_NEAREST_DEPOT) != 0)) {
- return
- this->GetDepotOrderType() == other.GetDepotOrderType() &&
- (this->GetDepotActionType() & ~ODATFB_NEAREST_DEPOT) == (other.GetDepotActionType() & ~ODATFB_NEAREST_DEPOT);
+ return this->GetDepotOrderType() == other.GetDepotOrderType() &&
+ (this->GetDepotActionType() & ~ODATFB_NEAREST_DEPOT) == (other.GetDepotActionType() & ~ODATFB_NEAREST_DEPOT);
}
- return
- this->type == other.type &&
- this->flags == other.flags &&
- this->dest == other.dest;
+ return this->type == other.type && this->flags == other.flags && this->dest == other.dest;
}
uint32 Order::Pack() const
@@ -1752,8 +1748,8 @@ bool ProcessOrders(Vehicle *v)
bool Order::ShouldStopAtStation(const Vehicle *v, StationID station) const
{
bool is_dest_station = this->IsType(OT_GOTO_STATION) && this->dest == station;
- return
- (!this->IsType(OT_GOTO_DEPOT) || (this->GetDepotOrderType() & ODTFB_PART_OF_ORDERS) != 0) &&
+
+ return (!this->IsType(OT_GOTO_DEPOT) || (this->GetDepotOrderType() & ODTFB_PART_OF_ORDERS) != 0) &&
v->last_station_visited != station && // Do stop only when we've not just been there
/* Finally do stop when there is no non-stop flag set for this type of station. */
!(this->GetNonStopType() & (is_dest_station ? ONSF_NO_STOP_AT_DESTINATION_STATION : ONSF_NO_STOP_AT_INTERMEDIATE_STATIONS));