Hey everybody,
I have a little problem with posting scores to the leaderboards (player statistics)
I gave players the permission to alter their statistics.
I have posted the script under this line but it wont give any results back.
public void UpdateGlobalScore(int score)
{
UpdatePlayerStatisticsRequest request = new UpdatePlayerStatisticsRequest()
{
Statistics = new List<StatisticUpdate>
{
new StatisticUpdate {StatisticName = "global" ,Value = score, Version = 0 }
}
};
PlayFabClientAPI.UpdatePlayerStatistics(request, (result) => { Debug.Log("Score Updated"); }, (error) => { Debug.Log("ERROR"); });
}
Can someone please tell me what i am doing wrong?