Instance Property

rank

The position of the score in the results of a leaderboard search.

Declaration

iOS, Mac Catalyst, tvOS, watchOS
@property(readonly, assign, nonatomic) NSInteger rank;
macOS
@property(readonly, assign, atomic) NSInteger rank;

Discussion

The value of this property is only valid on score objects returned from Game Center. The rank property represents the position of the score in the returned results, with 1 being the best score, 2 being the second best, and so on.

See Also

Score Properties

context

An integer value used by your game.

date

The date and time when the score was earned.

formattedValue

Returns the player’s score as a localized string.

leaderboardIdentifier

The identifier for the leaderboard.

player

The player identifier for the player that earned the score.

value

The score earned by the player.