1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2025-12-10 09:32:29 +01:00

Fix new ride window authors (#24773)

This commit is contained in:
mix
2025-07-16 12:07:39 +01:00
committed by GitHub
parent ba13285784
commit fe5a47c6b1
2 changed files with 5 additions and 6 deletions

View File

@@ -4,6 +4,7 @@
- Feature: [#24702] [Plugin] Add bindings for missing cheats (forcedParkRating, ignoreRidePrice, makeAllDestructible).
- Change: [#24730] Security guards now only walk slowly in crowded areas.
- Fix: [#24598] Cannot load .park files that use official legacy footpaths by accident.
- Fix: [#24773] The new ride window debug authors does not show the correct authors for non legacy ride objects.
0.4.24 (2025-07-05)
------------------------------------------------------------------------

View File

@@ -980,14 +980,12 @@ namespace OpenRCT2::Ui::Windows
}
// Draw object author(s) if debugging tools are active
if (Config::Get().general.DebuggingTools)
if (Config::Get().general.DebuggingTools && !rideObj->GetAuthors().empty())
{
auto repoItem = ObjectRepositoryFindObjectByEntry(&(rideObj->GetObjectEntry()));
StringId authorStringId = repoItem->Authors.size() > 1 ? STR_AUTHORS_STRING : STR_AUTHOR_STRING;
const auto& authors = rideObj->GetAuthors();
std::string authorsString;
for (auto& author : repoItem->Authors)
for (auto& author : authors)
{
if (!authorsString.empty())
authorsString.append(", ");
@@ -996,7 +994,7 @@ namespace OpenRCT2::Ui::Windows
}
ft = Formatter();
ft.Add<StringId>(authorStringId);
ft.Add<StringId>(authors.size() > 1 ? STR_AUTHORS_STRING : STR_AUTHOR_STRING);
ft.Add<const char*>(authorsString.c_str());
DrawTextEllipsised(