question

andrzejkorolczuk avatar image
andrzejkorolczuk asked

Statistics field comes back empty for current player in GetLeaderboardAroundPlayer request

Hi

When downloading leaderboards around player I noticed that "Statistics" field is completely empty for the current user. Everybody else's are filled correctly. Is this by design or is it a bug?

The call I'm making is:

GetLeaderboardAroundPlayerRequest request = new GetLeaderboardAroundPlayerRequest{
                
StatisticName = "Rank",
MaxResultsCount = 50,
ProfileConstraints = new PlayerProfileViewConstraints
{
ShowStatistics = true,
ShowDisplayName = true
}
};

PlayFabClientAPI.GetLeaderboardAroundPlayer(
request,
result =>
{
//stuff
}
Leaderboards and Statistics
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

·
Hernando avatar image
Hernando answered

The current user should work like else's. I run the code you posted, but I can’t reproduce your issue. Can you modify the MaxResultsCount to a small value and post the detail of response you get.

2 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.

andrzejkorolczuk avatar image andrzejkorolczuk commented ·

Hey

Posted both request nad response json here: https://pastebin.com/Ah2JZSFg

Thanks

0 Likes 0 ·
andrzejkorolczuk avatar image andrzejkorolczuk andrzejkorolczuk commented ·

I just noticed that the player in question does not have any statistics in his profile so this is probably why.. Sorry I sohuld've checked that

0 Likes 0 ·

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.