Fixes to auto timetable patch: move new VehicleFlags to end,
whitespace & style, fix lang strings.
This commit is contained in:
@@ -1398,11 +1398,11 @@ STR_CONFIG_SETTING_ADVANCED_VEHICLE_LISTS :Use groups in v
|
||||
STR_CONFIG_SETTING_ADVANCED_VEHICLE_LISTS_HELPTEXT :Enable usage of the advanced vehicle lists for grouping vehicles
|
||||
STR_CONFIG_SETTING_LOADING_INDICATORS :Use loading indicators: {STRING2}
|
||||
STR_CONFIG_SETTING_LOADING_INDICATORS_HELPTEXT :Select whether loading indicators are displayed above loading or unloading vehicles
|
||||
STR_CONFIG_SETTING_TIMETABLE_AUTOMATED :{LTBLUE}Automatically manage timetables: {ORANGE}{STRING2}
|
||||
STR_CONFIG_SETTING_TIMETABLE_AUTOMATED :Automatically manage timetables: {STRING2}
|
||||
STR_CONFIG_SETTING_TIMETABLE_AUTOMATED_HELPTEXT :Whether to enable automatic timetables
|
||||
STR_CONFIG_SETTING_TIMETABLE_IN_TICKS :Show timetable in ticks rather than days: {STRING2}
|
||||
STR_CONFIG_SETTING_TIMETABLE_IN_TICKS_HELPTEXT :Show travel times in time tables in game ticks instead of days
|
||||
STR_CONFIG_SETTING_TIMETABLE_SEPARATION :{LTBLUE}Use timetable to ensure vehicle separation: {ORANGE}{STRING2}
|
||||
STR_CONFIG_SETTING_TIMETABLE_SEPARATION :Use timetable to ensure vehicle separation: {STRING2}
|
||||
STR_CONFIG_SETTING_TIMETABLE_SEPARATION_HELPTEXT :Select whether to ensure separation of vehicles when using automatic timetables
|
||||
STR_CONFIG_SETTING_TIMETABLE_SHOW_ARRIVAL_DEPARTURE :Show arrival and departure in timetables: {STRING2}
|
||||
STR_CONFIG_SETTING_TIMETABLE_SHOW_ARRIVAL_DEPARTURE_HELPTEXT :Display anticipated arrival and departure times in timetables
|
||||
|
@@ -1622,8 +1622,9 @@ CommandCost CmdCloneOrder(TileIndex tile, DoCommandFlag flags, uint32 p1, uint32
|
||||
|
||||
|
||||
/* Set automation bit if target has it. */
|
||||
if (HasBit(src->vehicle_flags, VF_AUTOMATE_TIMETABLE))
|
||||
if (HasBit(src->vehicle_flags, VF_AUTOMATE_TIMETABLE)) {
|
||||
SetBit(dst->vehicle_flags, VF_AUTOMATE_TIMETABLE);
|
||||
}
|
||||
|
||||
if (_settings_game.order.timetable_separation) dst->ClearSeparation();
|
||||
if (_settings_game.order.timetable_separation) ClrBit(dst->vehicle_flags, VF_TIMETABLE_STARTED);
|
||||
|
@@ -56,8 +56,7 @@ public:
|
||||
offset(0),
|
||||
num_param(size)
|
||||
{
|
||||
uint left = parent.GetDataLeft();
|
||||
assert(size <= left);
|
||||
assert(size <= parent.GetDataLeft());
|
||||
if (parent.type == NULL) {
|
||||
this->type = NULL;
|
||||
} else {
|
||||
|
@@ -2142,8 +2142,9 @@ void Vehicle::HandleLoading(bool mode)
|
||||
uint wait_time = max(this->current_order.GetTimetabledWait() - this->lateness_counter, 0);
|
||||
|
||||
/* Save time just loading took since that is what goes into the timetable */
|
||||
if (!HasBit(this->vehicle_flags, VF_LOADING_FINISHED))
|
||||
if (!HasBit(this->vehicle_flags, VF_LOADING_FINISHED)) {
|
||||
this->current_loading_time = this->current_order_time;
|
||||
}
|
||||
|
||||
/* Not the first call for this tick, or still loading */
|
||||
if (mode || !HasBit(this->vehicle_flags, VF_LOADING_FINISHED) || this->current_order_time < wait_time) return;
|
||||
|
@@ -46,11 +46,11 @@ enum VehicleFlags {
|
||||
VF_TIMETABLE_STARTED, ///< Whether the vehicle has started running on the timetable yet.
|
||||
VF_AUTOFILL_TIMETABLE, ///< Whether the vehicle should fill in the timetable automatically.
|
||||
VF_AUTOFILL_PRES_WAIT_TIME, ///< Whether non-destructive auto-fill should preserve waiting times
|
||||
VF_AUTOMATE_TIMETABLE, ///< Whether the vehicle should manage the timetable automatically.
|
||||
VF_STOP_LOADING, ///< Don't load anymore during the next load cycle.
|
||||
VF_PATHFINDER_LOST, ///< Vehicle's pathfinder is lost.
|
||||
VF_SERVINT_IS_CUSTOM, ///< Service interval is custom.
|
||||
VF_SERVINT_IS_PERCENT, ///< Service interval is percent.
|
||||
VF_AUTOMATE_TIMETABLE, ///< Whether the vehicle should manage the timetable automatically.
|
||||
};
|
||||
|
||||
/** Bit numbers used to indicate which of the #NewGRFCache values are valid. */
|
||||
|
Reference in New Issue
Block a user