(svn r16165) -Add [FS#2801] [NoAI]: several functions to AIOrder to check the what kind of order an order is.

-Fix: AIOrder::GetOrderDestination and AIOrder::GetOrderFlags didn't work on ORDER_CURRENT when the vehicle was loading/leaving in a station.
This commit is contained in:
yexo
2009-04-26 16:14:53 +00:00
parent 779640b53a
commit 9101de49d8
6 changed files with 184 additions and 83 deletions

View File

@@ -431,6 +431,16 @@ public:
*/
static bool SendVehicleToDepot(VehicleID vehicle_id);
/**
* Sends the given vehicle to a depot for servicing. If the vehicle has
* already been sent to a depot it continues with its normal orders instead.
* @param vehicle_id The vehicle to send to a depot for servicing.
* @pre IsValidVehicle(vehicle_id).
* @exception AIVehicle::ERR_VEHICLE_CANNOT_SEND_TO_DEPOT
* @return True if the current order was changed.
*/
static bool SendVehicleToDepotForServicing(VehicleID vehicle_id);
/**
* Starts or stops the given vehicle depending on the current state.
* @param vehicle_id The vehicle to start/stop.