From f404f3154e51cd592ead7ab80c3ee69a0460eaa3 Mon Sep 17 00:00:00 2001 From: Peter Nelson Date: Wed, 8 Jan 2025 19:37:38 +0000 Subject: [PATCH] Fix #13293: Incorrect GRFStringID used for industry cargo suffix text. (#13294) Industry cargo suffix string should be mapped to 0xD000-0xD400 when the callback result is between 0x800-0xC00, --- src/industry_gui.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/industry_gui.cpp b/src/industry_gui.cpp index 41ab165a9d..524fed7d76 100644 --- a/src/industry_gui.cpp +++ b/src/industry_gui.cpp @@ -127,7 +127,7 @@ static void GetCargoSuffix(uint cargo, CargoSuffixType cst, const Industry *ind, } if (callback >= 0x800 && callback < 0xC00) { StartTextRefStackUsage(indspec->grf_prop.grffile, 6); - suffix.text = GetString(GetGRFStringID(indspec->grf_prop.grfid, GRFSTR_MISC_GRF_TEXT + callback)); + suffix.text = GetString(GetGRFStringID(indspec->grf_prop.grfid, GRFSTR_MISC_GRF_TEXT + callback - 0x800)); StopTextRefStackUsage(); suffix.display = CSD_CARGO_TEXT; return;