Skip to main content
Version: 5.7.0

PostScoreToDynamicGroupLeaderboardUTC

Post the group score to the given group leaderboard and dynamically create if necessary. LeaderboardType, rotationType, rotationReset, and retainedCount are required.

ServiceOperation
leaderboardPOST_GROUP_SCORE
caution

This API is deprecated. Please use PostScoreToDynamicGroupLeaderboardUsingConfig instead.

Method Parameters

ParameterDescription
leaderboardIdThe id of the leaderboard.
groupIdThe id of the group.
scoreThe score to post.
dataOptional user-defined data to post with the score.
leaderboardTypethe type of leaderboard
rotationTypedaily, weekly, monthly
rotationResetTimethe date to reset the rotation in milliseconds UTC
retainedCounttimes to retain the leaderboard

Usage

http://localhost:3000
string leaderboardId = "default";
string groupId = "actual_group_id";
int score = 10;
string data = "{\"nickname\":\"batman\"}";
SocialLeaderboardType leaderboardType = "HIGH_VALUE";
RotationType rotationType = "WEEKLY";
Int64 rotationResetTime = 15346346346;
int retainedCount = 2;
SuccessCallback successCallback = (response, cbObject) =>
{
Debug.Log(string.Format("Success | {0}", response));
};
FailureCallback failureCallback = (status, code, error, cbObject) =>
{
Debug.Log(string.Format("Failed | {0} {1} {2}", status, code, error));
};

_bc.LeaderboardService.PostScoreToDynamicGroupLeaderboardUTC(leaderboardId, groupId, score, data, leaderboardType, rotationType, rotationResetTime, retainedCount, successCallback, failureCallback);
JSON Response
{
"status": 200,
"data": null
}