question

glen avatar image
glen asked

Limit on server Leaderboard count

Is there a limit for MaxResultsCount in regards to server calls for leaderboards? I've noticed that in the documentation a limit of 100 exists for client calls but there is no limit expressed for the same server leaderboard calls.

CloudScript
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

1 Answer

·
brendan avatar image
brendan answered

I'll get the docs updated for that - it's the same call, effectively, and with the same limit (100). What is the scenario you have in mind that would require a higher limit?

7 comments
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

glen avatar image glen commented ·

The scenario would be in regards to friends. From what I can tell there is no limit on friends count. So when creating a leaderboard for your friends it might be nice to be able to accommodate all your friends.

0 Likes 0 ·
glen avatar image glen commented ·

A friend leaderboard seems like a simple way of displaying a friends list. Instead of using GetFriendsList we could just use GetFriendLeaderboard. Then it's even pre-sorted and critical information is already contained in the leaderboard such as PlayFabId and DisplayName.

0 Likes 0 ·
brendan avatar image brendan glen commented ·

Could you clarify the actual use case, though? In what context would a player need to be able to see all the scores for all his friends at once, if he has thousands of friends?

0 Likes 0 ·
glen avatar image glen glen commented ·

Imagine a typical friends list, but it's sorted by a leaderboard statistic. So the use case is using the leaderboard as a friends list instead of using GetFriendsList. Using GetFriendsList wouldn't allow sorting by a leaderboard statistic. In this case the game has a pervasive and very important statistic which denotes your skill in the game. This statistic is used to sort the friends list instead of sorting friends alphabetically or by some other measure.

I think this method would encounter issues with thousands of players simply for UX reasons. So maybe we'd impose our own limit on friend count, perhaps 200 - 300. But we'd still run into the 100 limit for leaderboards. I imagine we could use pages to break up the friends list, but that isn't the current design.

I expect it doesn't make sense to return all entries for very high friend counts though, eg: 500+. There has to be a limit of some kind.

0 Likes 0 ·
brendan avatar image brendan glen commented ·

The UX issues are what I was really referring to - given that we're already sorting the list by the statistic reported, there wouldn't seem to be a need to grab "all friends" (or, more to the point, a useful way to present all that to the user). But yes, you could use the StartPosition as a way to get the next page, as long as you're waiting between each call (that is to say, don't send multiple simultaneous requests from a single client - wait a second after the response before the next query).

0 Likes 0 ·
Show more comments

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.