Feature: Separate rail/road and sea/air velocity units, and add knots. (#10594)

This is achieved by packing vehicle type along with the velocity so that
the string system can decode and pick the appropriate unit.
This commit is contained in:
PeterN
2023-04-08 17:26:13 +01:00
committed by GitHub
parent 3a48d6e60f
commit f1144de509
17 changed files with 117 additions and 60 deletions

View File

@@ -195,6 +195,7 @@ STR_UNITS_VELOCITY_IMPERIAL :{COMMA}{NBSP}mp
STR_UNITS_VELOCITY_METRIC :{COMMA}{NBSP}km/h
STR_UNITS_VELOCITY_SI :{COMMA}{NBSP}m/s
STR_UNITS_VELOCITY_GAMEUNITS :{DECIMAL}{NBSP}tiles/day
STR_UNITS_VELOCITY_KNOTS :{COMMA}{NBSP}knots
STR_UNITS_POWER_IMPERIAL :{COMMA}{NBSP}hp
STR_UNITS_POWER_METRIC :{COMMA}{NBSP}hp
@@ -1951,13 +1952,15 @@ STR_CONFIG_SETTING_DEMAND_SIZE_HELPTEXT :Setting this to
STR_CONFIG_SETTING_SHORT_PATH_SATURATION :Saturation of short paths before using high-capacity paths: {STRING2}
STR_CONFIG_SETTING_SHORT_PATH_SATURATION_HELPTEXT :Frequently there are multiple paths between two given stations. Cargodist will saturate the shortest path first, then use the second shortest path until that is saturated and so on. Saturation is determined by an estimation of capacity and planned usage. Once it has saturated all paths, if there is still demand left, it will overload all paths, prefering the ones with high capacity. Most of the time the algorithm will not estimate the capacity accurately, though. This setting allows you to specify up to which percentage a shorter path must be saturated in the first pass before choosing the next longer one. Set it to less than 100% to avoid overcrowded stations in case of overestimated capacity.
STR_CONFIG_SETTING_LOCALISATION_UNITS_VELOCITY :Speed units: {STRING2}
STR_CONFIG_SETTING_LOCALISATION_UNITS_VELOCITY :Speed units (land): {STRING2}
STR_CONFIG_SETTING_LOCALISATION_UNITS_VELOCITY_NAUTICAL :Speed units (nautical): {STRING2}
STR_CONFIG_SETTING_LOCALISATION_UNITS_VELOCITY_HELPTEXT :Whenever a speed is shown in the user interface, show it in the selected units
###length 4
###length 5
STR_CONFIG_SETTING_LOCALISATION_UNITS_VELOCITY_IMPERIAL :Imperial (mph)
STR_CONFIG_SETTING_LOCALISATION_UNITS_VELOCITY_METRIC :Metric (km/h)
STR_CONFIG_SETTING_LOCALISATION_UNITS_VELOCITY_SI :SI (m/s)
STR_CONFIG_SETTING_LOCALISATION_UNITS_VELOCITY_GAMEUNITS :Game units (tiles/day)
STR_CONFIG_SETTING_LOCALISATION_UNITS_VELOCITY_KNOTS :Knots
STR_CONFIG_SETTING_LOCALISATION_UNITS_POWER :Vehicle power units: {STRING2}
STR_CONFIG_SETTING_LOCALISATION_UNITS_POWER_HELPTEXT :Whenever a vehicle's power is shown in the user interface, show it in the selected units