Codechange: Use local parameters for formatting settings values. (#13487)

This commit is contained in:
Peter Nelson
2025-02-07 20:18:03 +00:00
committed by GitHub
parent 9a6fc4eb76
commit d9bb002cac
7 changed files with 58 additions and 60 deletions

View File

@@ -11,8 +11,8 @@
static void UpdateAllServiceInterval(int32_t new_value);
static bool CanUpdateServiceInterval(VehicleType type, int32_t &new_value);
static void UpdateServiceInterval(VehicleType type, int32_t new_value);
static void SettingsValueAbsolute(const IntSettingDesc &sd, uint first_param, int32_t value);
static void ServiceIntervalSettingsValueText(const IntSettingDesc &sd, uint first_param, int32_t value);
static std::pair<StringParameter, StringParameter> SettingsValueAbsolute(const IntSettingDesc &sd, int32_t value);
static std::pair<StringParameter, StringParameter> ServiceIntervalSettingsValueText(const IntSettingDesc &sd, int32_t value);
static int32_t GetDefaultServiceInterval(const IntSettingDesc &sd, VehicleType type);
static std::tuple<int32_t, uint32_t> GetServiceIntervalRange(const IntSettingDesc &sd);

View File

@@ -8,7 +8,7 @@
; in the savegame PATS chunk. These settings are not sync'd over the network.
[pre-amble]
static void SettingsValueVelocityUnit(const IntSettingDesc &sd, uint first_param, int32_t value);
static std::pair<StringParameter, StringParameter> SettingsValueVelocityUnit(const IntSettingDesc &sd, int32_t value);
uint8_t _old_units; ///< Old units from old savegames