Type function Library gamecircle.* Return value None Revision Release 2022.3683 Keywords gamecircle, player, profile
This function allows you to fetch the Player information of the local player's friends based on provided Id's.
gamecircle.GetBatchFriends(idsTable, callback)
Table. A table of ids for the local player's friends. These Id's can be fetched using [GetFriendsIds][gamecircle.GetFriendsIds]. As seen in the example below, the result of [GetFriendsIds][gamecircle.GetFriendsIds] can be fed straight into this function to provide ids. If, however, you wish to build your own table of ids, then the ids must be stored correctly. They must be of type String and stored in a table via square bracket accessors with consecuitive numbering.
Function. Pass to a callback function since the request requires the GameCircle SDK to contact Amazon's servers. The callback will recieve a single parameter of a [FriendIdsReturn][gamecircle.FriendIdsReturn].
local gamecircle = require("plugin.gamecircle") gamecircle.Init(true, false, false) function FriendIdsCallback(returnTable) if returnTable.isError == true then print("Friend Ids Callback had an error: " .. returnTable.errorMessage) else print("===================Friend Ids Callback has returned!") for i = 1, returnTable.num do print("Friend Ids Found + " .. returnTable[i]) end gamecircle.GetBatchFriends(returnTable, BatchFriendsCallback) end end function BatchFriendsCallback(returnTable) if returnTable.isError == true then print("Batch Friends Callback had an error: " .. returnTable.errorMessage) else print("===================Batch Friends Callback has returned!") for i = 1, returnTable.num do print("--Friend Found: " .. returnTable[i].alias) end gamecircle.GetBatchFriends(returnTable, BatchFriendsCallback) end end gamecircle.GetFriendIds(FriendIdsCallback)