diff src/order_cmd.cpp @ 15767:293a91934c7d draft

(svn r20441) -Fix [FS#4024]: adding "goto nearest depot and stop" orders in one go was denied. This caused both AI adding those orders and backed up order restoration to fail.
author rubidium <rubidium@openttd.org>
date Tue, 10 Aug 2010 16:45:32 +0000 (2010-08-10)
parents f8e9a3f0c140
children 6a1b604d137f
line wrap: on
line diff
--- a/src/order_cmd.cpp
+++ b/src/order_cmd.cpp
@@ -525,7 +525,7 @@
 		}
 
 		case OT_GOTO_DEPOT: {
-			if (new_order.GetDepotActionType() != ODATFB_NEAREST_DEPOT) {
+			if ((new_order.GetDepotActionType() & ODATFB_NEAREST_DEPOT) == 0) {
 				if (v->type == VEH_AIRCRAFT) {
 					const Station *st = Station::GetIfValid(new_order.GetDestination());