summaryrefslogtreecommitdiff
path: root/src/aircraft_cmd.cpp
diff options
context:
space:
mode:
authorrubidium <rubidium@openttd.org>2008-01-15 18:44:22 +0000
committerrubidium <rubidium@openttd.org>2008-01-15 18:44:22 +0000
commit576f8ad93e5eb2d2c2777ae1e448ae80e80d14ba (patch)
tree7948f0844d640b0be32729fdeaf9be3da5453758 /src/aircraft_cmd.cpp
parentab7cb0804de68b015dcc774a4fbcc82e356d2c87 (diff)
downloadopenttd-576f8ad93e5eb2d2c2777ae1e448ae80e80d14ba.tar.xz
(svn r11866) -Codechange: swap OFB_* and OF_* so it conceptually in sync with other cases of *B_* vs *_* like VETSB_* and VETS_*.
Diffstat (limited to 'src/aircraft_cmd.cpp')
-rw-r--r--src/aircraft_cmd.cpp18
1 files changed, 9 insertions, 9 deletions
diff --git a/src/aircraft_cmd.cpp b/src/aircraft_cmd.cpp
index a8ce785e8..f8cdc2837 100644
--- a/src/aircraft_cmd.cpp
+++ b/src/aircraft_cmd.cpp
@@ -569,13 +569,13 @@ CommandCost CmdSendAircraftToHangar(TileIndex tile, uint32 flags, uint32 p1, uin
if (v->type != VEH_AIRCRAFT || !CheckOwnership(v->owner) || v->IsInDepot()) return CMD_ERROR;
if (v->current_order.type == OT_GOTO_DEPOT && !(p2 & DEPOT_LOCATE_HANGAR)) {
- if (!!(p2 & DEPOT_SERVICE) == HasBit(v->current_order.flags, OFB_HALT_IN_DEPOT)) {
+ if (!!(p2 & DEPOT_SERVICE) == HasBit(v->current_order.flags, OF_HALT_IN_DEPOT)) {
/* We called with a different DEPOT_SERVICE setting.
* Now we change the setting to apply the new one and let the vehicle head for the same hangar.
* Note: the if is (true for requesting service == true for ordered to stop in hangar) */
if (flags & DC_EXEC) {
- ClrBit(v->current_order.flags, OFB_PART_OF_ORDERS);
- ToggleBit(v->current_order.flags, OFB_HALT_IN_DEPOT);
+ ClrBit(v->current_order.flags, OF_PART_OF_ORDERS);
+ ToggleBit(v->current_order.flags, OF_HALT_IN_DEPOT);
InvalidateWindowWidget(WC_VEHICLE_VIEW, v->index, STATUS_BAR);
}
return CommandCost();
@@ -583,7 +583,7 @@ CommandCost CmdSendAircraftToHangar(TileIndex tile, uint32 flags, uint32 p1, uin
if (p2 & DEPOT_DONT_CANCEL) return CMD_ERROR; // Requested no cancelation of hangar orders
if (flags & DC_EXEC) {
- if (v->current_order.flags & OF_UNLOAD) v->cur_order_index++;
+ if (v->current_order.flags & OFB_UNLOAD) v->cur_order_index++;
v->current_order.type = OT_DUMMY;
v->current_order.flags = 0;
InvalidateWindowWidget(WC_VEHICLE_VIEW, v->index, STATUS_BAR);
@@ -606,8 +606,8 @@ CommandCost CmdSendAircraftToHangar(TileIndex tile, uint32 flags, uint32 p1, uin
if (v->current_order.type == OT_LOADING) v->LeaveStation();
v->current_order.type = OT_GOTO_DEPOT;
- v->current_order.flags = OF_NON_STOP;
- if (!(p2 & DEPOT_SERVICE)) SetBit(v->current_order.flags, OFB_HALT_IN_DEPOT);
+ v->current_order.flags = OFB_NON_STOP;
+ if (!(p2 & DEPOT_SERVICE)) SetBit(v->current_order.flags, OF_HALT_IN_DEPOT);
v->current_order.refit_cargo = CT_INVALID;
v->current_order.dest = next_airport_index;
InvalidateWindowWidget(WC_VEHICLE_VIEW, v->index, STATUS_BAR);
@@ -714,7 +714,7 @@ static void CheckIfAircraftNeedsService(Vehicle *v)
// printf("targetairport = %d, st->index = %d\n", v->u.air.targetairport, st->index);
// v->u.air.targetairport = st->index;
v->current_order.type = OT_GOTO_DEPOT;
- v->current_order.flags = OF_NON_STOP;
+ v->current_order.flags = OFB_NON_STOP;
InvalidateWindowWidget(WC_VEHICLE_VIEW, v->index, STATUS_BAR);
} else if (v->current_order.type == OT_GOTO_DEPOT) {
v->current_order.type = OT_DUMMY;
@@ -1347,8 +1347,8 @@ static void ProcessAircraftOrder(Vehicle *v)
{
switch (v->current_order.type) {
case OT_GOTO_DEPOT:
- if (!(v->current_order.flags & OF_PART_OF_ORDERS)) return;
- if (v->current_order.flags & OF_SERVICE_IF_NEEDED &&
+ if (!(v->current_order.flags & OFB_PART_OF_ORDERS)) return;
+ if (v->current_order.flags & OFB_SERVICE_IF_NEEDED &&
!VehicleNeedsService(v)) {
UpdateVehicleTimetable(v, true);
v->cur_order_index++;