mirror of
https://github.com/OpenTTD/OpenTTD
synced 2026-01-18 09:52:44 +01:00
Codechange: Use GetString() with argument parameters in simple cases. (#13551)
Avoids using global string parameters.
This commit is contained in:
@@ -284,9 +284,7 @@ std::optional<std::string> BuildCargoAcceptanceString(const CargoArray &acceptan
|
||||
|
||||
/* If the accepted value is less than 8, show it in 1/8:ths */
|
||||
if (acceptance[cargo_type] < 8) {
|
||||
SetDParam(0, acceptance[cargo_type]);
|
||||
SetDParam(1, cs->name);
|
||||
line << GetString(STR_LAND_AREA_INFORMATION_CARGO_EIGHTS);
|
||||
line << GetString(STR_LAND_AREA_INFORMATION_CARGO_EIGHTS, acceptance[cargo_type], cs->name);
|
||||
} else {
|
||||
line << GetString(cs->name);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user