Fix solo leaderboard sometimes not showing user position while it technically could #35400
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The "partial" leaderboard logic in
SoloGameplayLeaderboardProvideralways assumed the online fetch would request 50 scores, which is no longer the case after #33100.Noticed in https://discord.com/channels/188630481301012481/188630652340404224/1430503761440149554.
The circumstances where this matters are pretty rare. You'd basically need to find an online leaderboard (friends / country / with selected mods) that has between 50 and 100 scores - if you do and then enter gameplay, the tracked score won't show a rank when it's last, even though it can. One such example I found that's usable right now is https://osu.ppy.sh/beatmapsets/2400092#osu/5204282, scoped to Hidden mod, which returns 63 online scores.
Because this uses the total score count as returned by web, it's probably also more accurate when a leaderboard has precisely 50 scores, but that's even more difficult to confirm, so I won't even try.