Skip to content

Commit

Permalink
Fix: "-q" displays NewGRF IDs in the wrong byte-order (OpenTTD#12397)
Browse files Browse the repository at this point in the history
  • Loading branch information
TrueBrain authored and michicc committed Mar 31, 2024
1 parent 12c22ab commit 4fc15ee
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/openttd.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -246,7 +246,7 @@ static void WriteSavegameInfo(const std::string &name)
message += "NewGRFs:\n";
if (_load_check_data.HasNewGrfs()) {
for (GRFConfig *c = _load_check_data.grfconfig; c != nullptr; c = c->next) {
fmt::format_to(std::back_inserter(message), "{:08X} {} {}\n", c->ident.grfid,
fmt::format_to(std::back_inserter(message), "{:08X} {} {}\n", BSWAP32(c->ident.grfid),
FormatArrayAsHex(HasBit(c->flags, GCF_COMPATIBLE) ? c->original_md5sum : c->ident.md5sum), c->filename);
}
}
Expand Down

0 comments on commit 4fc15ee

Please sign in to comment.