SC_ScoresController
Instances of SC_ScoresController retrieve lists of scores from the server.
Basic use:
-
Get an instance of SC_Client .
-
Use the client instance to call SC_Client_CreateScoresController() .
-
Search criteria can be set as follows: Specify the search list for the controller by calling SC_ScoresController_SetSearchList() . You can specify the following search lists: SC_SCORES_SEARCH_LIST_ALL, SC_SCORES_SEARCH_LIST_24H, or SC_SCORES_SEARCH_LIST_USER_COUNTRY.
-
Set the mode for the controller by calling SC_ScoresController_SetMode() .
-
Request the scores by using one of the following loadScores methods:
-
Wait for a successful server response via delegate callbacks.
-
Once the request is complete, access the scores that were returned by calling SC_ScoresController_GetScores() .
To page through additional scores:
-
Call SC_ScoresController_HasNextRange() and SC_ScoresController_HasPreviousRange() to determine if it is possible to page.
-
Use SC_ScoresController_LoadNextRange() or SC_ScoresController_LoadPreviousRange() to request the next or previous list of scores from the server.
-
After a successful server response, access the SC_Scores_list that was returned, by calling SC_ScoresController_GetScores() .