1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2026-01-26 16:24:35 +01:00

Scripting: order available costumes array by display name (#25228)

This commit is contained in:
Aaron van Geffen
2025-09-21 17:31:36 +02:00
committed by GitHub
parent f9e9cefb46
commit db5f56f4aa
3 changed files with 5 additions and 0 deletions

View File

@@ -2,6 +2,7 @@
------------------------------------------------------------------------
- Improved: [#2296, #2307] The land tool now takes sloped track and paths into account when modifying land.
- Change: [#25161] Revert to the fair ride price calculation of vanilla RCT2.
- Change: [#25228] [Plugin] The available staff costumes array is now ordered alphabetically by name.
- Fix: [#24513] Ride/track designs can now be shifted underground as well.
- Fix: [#24682] The scenery window isn't enough to accommodate all tool buttons when there are multiple rows of groups/tabs.
- Fix: [#24882] Guests are shown with hats and umbrellas whilst clapping.

View File

@@ -233,11 +233,14 @@ namespace OpenRCT2
.objectId = ObjectEntryIndex(i),
.group = group,
.legacyPosition = animObj->GetLegacyPosition(group),
.rawName = animObj->GetCostumeName(),
.scriptName = scriptName,
});
}
}
std::sort(groups.begin(), groups.end(), [](const auto& a, const auto& b) { return a.rawName < b.rawName; });
return groups;
}

View File

@@ -85,6 +85,7 @@ namespace OpenRCT2
ObjectEntryIndex objectId;
PeepAnimationGroup group;
RCT12PeepAnimationGroup legacyPosition;
std::string rawName;
std::string_view scriptName;
};