Contents

init(leaderboardIdentifier:player:)

Returns an initialized score object for the specified leaderboard and player.

Declaration

init(leaderboardIdentifier identifier: String, player: GKPlayer)

Parameters

  • identifier:

    Identifies the leaderboard that the score is being sent to.

  • player:

    The Gkplayer object identifying the player who’s score is being initialized.

Return Value

An initialized score object, or nil if an error occurred.

Discussion

Your game explicitly allocates and initializes a score object using the designated player and current date when it needs to report a new score to Game Center.

See Also

Deprecated Methods and Properties