Contents

init(leaderboardID:playerScope:timeScope:)

Creates a view controller that presents a leaderboard with data from the specified players and time period.

Declaration

init(leaderboardID: String, playerScope: GKLeaderboard.PlayerScope, timeScope: GKLeaderboard.TimeScope)

Parameters

  • leaderboardID:

    The identifier for the leaderboard to display.

  • playerScope:

    The type of players to display in the leaderboard.

  • timeScope:

    The time period for the data to display in a classic leaderboard.

    For recurring leaderboards, this method ignores the time scope parameter and displays the data for the current occurrence instead.

Return Value

The initialized view controller.

See Also

Configuring Game Center content