--- a/src/vehicle_base.h Tue Apr 15 19:47:58 2008 +0000
+++ b/src/vehicle_base.h Wed Apr 16 00:07:47 2008 +0000
@@ -514,6 +514,24 @@
* @return the location (tile) to aim for.
*/
virtual TileIndex GetOrderStationLocation(StationID station) { return INVALID_TILE; }
+
+ /**
+ * Find the closest depot for this vehicle and tell us the location,
+ * DestinationID and whether we should reverse.
+ * @param location where do we go to?
+ * @param destination what hangar do we go to?
+ * @param reverse should the vehicle be reversed?
+ * @return true if a depot could be found.
+ */
+ virtual bool FindClosestDepot(TileIndex *location, DestinationID *destination, bool *reverse) { return false; }
+
+ /**
+ * Send this vehicle to the depot using the given command(s).
+ * @param flags the command flags (like execute and such).
+ * @param command the command to execute.
+ * @return the cost of the depot action.
+ */
+ CommandCost SendToDepot(uint32 flags, DepotCommand command);
};
/**