Instance Property

players

The players currently in the game.

Required.

Declaration

var players: [GKGameModelPlayer]? { get }

Discussion

This array should contain instances of your player class (a custom class implementing the GKGameModelPlayer protocol) representing the players in the game. When you use the GKMinmaxStrategist class to find an optimal move for a specific player, GameplayKit uses this array to rate the moves of that player’s opponent(s).

See Also

Keeping Track of Players

var activePlayer: GKGameModelPlayer?

The player whose turn it currently is in the game.

Required.