From d465257dd01ce9a61aa59951d789ee84c735f070 Mon Sep 17 00:00:00 2001 From: Peter Nelson Date: Sun, 21 Apr 2024 19:46:05 +0100 Subject: [PATCH] Fix 952d111: Houses and industry tiles could accept incorrect cargo. (#12547) Default cargo label was not cleared (set to CT_INVALID) when using older 3-slot acceptance properties for house and industry tiles. Missed in #12053 and #12062. --- src/newgrf.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/newgrf.cpp b/src/newgrf.cpp index 45208a3c9c..68396cdbca 100644 --- a/src/newgrf.cpp +++ b/src/newgrf.cpp @@ -2570,6 +2570,7 @@ static ChangeInfoResult TownHouseChangeInfo(uint hid, int numinfo, int prop, Byt } else { housespec->accepts_cargo[j] = cargo; } + housespec->accepts_cargo_label[j] = CT_INVALID; } break; } @@ -3306,6 +3307,7 @@ static ChangeInfoResult IndustrytilesChangeInfo(uint indtid, int numinfo, int pr uint16_t acctp = buf->ReadWord(); tsp->accepts_cargo[prop - 0x0A] = GetCargoTranslation(GB(acctp, 0, 8), _cur.grffile); tsp->acceptance[prop - 0x0A] = Clamp(GB(acctp, 8, 8), 0, 16); + tsp->accepts_cargo_label[prop - 0x0A] = CT_INVALID; break; }