Codechange: Don't save unused NewGRF override mappings. (#9202)
(cherry picked from commit 69e5da0b54
)
This commit is contained in:

committed by
Jonathan G Rennison

parent
879de9781b
commit
f52da3de3a
@@ -31,6 +31,7 @@ static const SaveLoad _newgrf_mapping_desc[] = {
|
||||
void Save_NewGRFMapping(const OverrideManagerBase &mapping)
|
||||
{
|
||||
for (uint i = 0; i < mapping.GetMaxMapping(); i++) {
|
||||
if (!mapping.IsValidID(i)) continue;
|
||||
SlSetArrayIndex(i);
|
||||
SlSetLength(4 + 1 + 1);
|
||||
SlObjectSaveFiltered(&mapping.mapping_ID[i], _newgrf_mapping_desc); // _newgrf_mapping_desc has no conditionals
|
||||
|
Reference in New Issue
Block a user