From 1a515e6344028854c855671c19f49d8f869eb18f Mon Sep 17 00:00:00 2001 From: rubidium Date: Sun, 1 May 2011 19:14:12 +0000 Subject: (svn r22405) -Document: some more "random-ish" tidbits --- src/timetable_cmd.cpp | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'src/timetable_cmd.cpp') diff --git a/src/timetable_cmd.cpp b/src/timetable_cmd.cpp index 32fc5feab..2145e89fc 100644 --- a/src/timetable_cmd.cpp +++ b/src/timetable_cmd.cpp @@ -18,6 +18,13 @@ #include "table/strings.h" +/** + * Change/update a particular timetable entry. + * @param v The vehicle to change the timetable of. + * @param order_number The index of the timetable in the order list. + * @param time The new time of the timetable entry. + * @param is_journey Whether to set the waiting or travelling time. + */ static void ChangeTimetable(Vehicle *v, VehicleOrderID order_number, uint16 time, bool is_journey) { Order *order = v->GetOrder(order_number); @@ -222,6 +229,11 @@ CommandCost CmdAutofillTimetable(TileIndex tile, DoCommandFlag flags, uint32 p1, return CommandCost(); } +/** + * Update the timetable for the vehicle. + * @param v The vehicle to update the timetable for. + * @param travelling Whether we just travelled or waited at a station. + */ void UpdateVehicleTimetable(Vehicle *v, bool travelling) { uint timetabled = travelling ? v->current_order.travel_time : v->current_order.wait_time; -- cgit v1.2.3-54-g00ecf