mirror of
https://github.com/OpenRCT2/OpenRCT2
synced 2025-12-21 14:53:02 +01:00
Use different name table offset depending on staff type (#22813)
This commit is contained in:
@@ -1608,7 +1608,14 @@ void Peep::FormatNameTo(Formatter& ft) const
|
||||
|
||||
if ((!isStaff && showGuestNames) || (isStaff && showStaffNames))
|
||||
{
|
||||
auto realNameStringId = GetRealNameStringIDFromPeepID(PeepId);
|
||||
auto nameId = PeepId;
|
||||
if (isStaff)
|
||||
{
|
||||
// Prevent staff from getting the same names by offsetting the name table based on staff type.
|
||||
nameId *= 256 * EnumValue(staff->AssignedStaffType) + 1;
|
||||
}
|
||||
|
||||
auto realNameStringId = GetRealNameStringIDFromPeepID(nameId);
|
||||
ft.Add<StringId>(realNameStringId);
|
||||
}
|
||||
else if (isStaff)
|
||||
|
||||
Reference in New Issue
Block a user