I want a list of all friends of the local player who also play my game.
I thought about doing a query for every friend score on every leaderboard, and finding distinct players:
GKLeaderboard *allScoresEver = [[GKLeaderboard alloc] init];
allScoresEver.playerScope = GKLeaderboardPlayerScopeFriendsOnly;
allScoresEver.range = NSMakeRange(1,100);
allScoresEver.category = nil;
[allScoresEver loadScoresWithCompletionHandler:^(NSArray *scores, NSError *error) {
// filter out distinct players, favouring scores from our leaderboard
...
}];
...but that seems to only return the last reported score of the local player, instead of every score from every leaderboard, filtered by friends. The docs say setting category to nil should return "all scores previously reported by the game". I guess that means the running instance of the game, not game in the sense of a world-wide app?
Any ideas of an effective way to get the results I want?