equal
deleted
inserted
replaced
674 |
674 |
675 /* Is it a valid order? */ |
675 /* Is it a valid order? */ |
676 if (sel_ord >= v->num_orders) return CMD_ERROR; |
676 if (sel_ord >= v->num_orders) return CMD_ERROR; |
677 |
677 |
678 order = GetVehicleOrder(v, sel_ord); |
678 order = GetVehicleOrder(v, sel_ord); |
679 if (order->type != OT_GOTO_STATION && |
679 if ((order->type != OT_GOTO_STATION || GetStation(order->dest)->IsBuoy()) && |
680 (order->type != OT_GOTO_DEPOT || p2 == OFB_UNLOAD) && |
680 (order->type != OT_GOTO_DEPOT || p2 == OFB_UNLOAD) && |
681 (order->type != OT_GOTO_WAYPOINT || p2 != OFB_NON_STOP)) { |
681 (order->type != OT_GOTO_WAYPOINT || p2 != OFB_NON_STOP)) { |
682 return CMD_ERROR; |
682 return CMD_ERROR; |
683 } |
683 } |
684 |
684 |