ios – Is it still possible to obtain the user’s rank from the Apple Game Center leaderboards?


I have some doubts about the Apple Game Center leaderboards.

1)
I noticed that the rank variable has been deprecated.
https://developer.apple.com/documentation/gamekit/gkscore/1399244-rank
Is there an alternative method to get the player’s rank in a given leaderboard?

2)
In the Unity plugin documentation I noticed that, when loading the entries of a leaderboard, it is possible to specify their scope (e.g. rank min = 1 and rank max = 100).
https://github.com/apple/unityplugins/blob/main/plug-ins/Apple.GameKit/Apple.GameKit_Unity/Assets/Apple.GameKit/Documentation~/Apple.GameKit.md?fbclid=IwAR3z6AU0POHOoARqXwwWxst9n65LBt1-ex_CKQ3eiqgvwKnbkgdrf-8dpv4#6-leaderboards

e.g:

var playerScope = GKLeaderboard.PlayerScope.Global;
var timeScope = GKLeaderboard.TimeScope.AllTime;
var rankMin = 1;
var rankMax = 100;

var scores = await leaderboard.LoadEntries(playerScope, timeScope, rankMin, rankMax);

But if I wanted to put a maximum reach as long as the list of users on the leaderboard, how could I get that value?

Latest articles

spot_imgspot_img

Related articles

Leave a reply

Please enter your comment!
Please enter your name here

spot_imgspot_img