Type Table Library gamecircle.* Revision Release 2024.3703 Keywords achievement
A representation of the score data returned by GameCircle SDK for some functions.
local leaderboardId = "myFirstLeaderboard" local gamecircle = require("plugin.gamecircle") gamecircle.Init(false, true, false) function LeaderboardCallback(returnValue) if returnValue.isError == true then print("Get Scores request returned with error message: " .. returnValue.errorMessage) else print("Score information recieved for Leaderboard!") print("-Leaderboard ID" .. returnValue.id) print("-name" .. returnValue.name) print("-displayText" .. returnValue.displayText) print("-num" .. returnValue.num) print("-scoreFormat" .. returnValue.scoreFormat) print("-scores:") for i, score in ipairs(returnValue) do print("--Rank " .. score.rank) print("---" .. score.scoreString .. " by " .. score.player.alias) end end end gamecircle.Leaderboard.GetScores(leaderboardId, "GLOBAL_WEEK", LeaderboardCallback)