/// <summary> /// Reports the score to game service server. /// </summary> /// <param name="_leaderboardGID">A string used to uniquely identify <see cref="VoxelBusters.NativePlugins.Leaderboard"/> across all supported platforms.</param> /// <param name="_score">The score earned by <see cref="VoxelBusters.NativePlugins.LocalUser"/></param> /// <param name="_onCompletion">Callback to be called when operation is completed.</param> public void ReportScoreWithGlobalID(string _leaderboardGID, long _score, Score.ReportScoreCompletion _onCompletion) { string _leaderboardID = GameServicesIDHandler.GetLeaderboardID(_leaderboardGID); // Invoke handler ReportScore(_leaderboardGID, _leaderboardID, _score, _onCompletion); }
/// <summary> /// Creates an instance of <see cref="VoxelBusters.NativePlugins.Leaderboard"/>. /// </summary> /// <returns>An initialized <see cref="VoxelBusters.NativePlugins.Leaderboard"/> instance.</returns> /// <param name="_leaderboardGID">A string used to uniquely identify <see cref="VoxelBusters.NativePlugins.Leaderboard"/> across all supported platforms.</param> public Leaderboard CreateLeaderboardWithGlobalID(string _leaderboardGID) { string _leaderboardID = GameServicesIDHandler.GetLeaderboardID(_leaderboardGID); return(CreateLeaderboard(_leaderboardGID, _leaderboardID)); }
/// <summary> /// Show the leaderboard UI with a specific time scope. /// </summary> /// <param name="_leaderboardGID">A string used to uniquely identify <see cref="VoxelBusters.NativePlugins.Leaderboard"/> across all supported platforms.</param> /// <param name="_timeScope">Time scope initially used while showing leaderboard UI.</param> /// <param name="_onCompletion">Callback called when Leaderboard view is closed.</param> public void ShowLeaderboardUIWithGlobalID(string _leaderboardGID, eLeaderboardTimeScope _timeScope, GameServiceViewClosed _onCompletion) { string _leaderboardID = GameServicesIDHandler.GetLeaderboardID(_leaderboardGID); ShowLeaderboardUIWithID(_leaderboardID, _timeScope, _onCompletion); }