A user interface that allows players to manage the turn-based matches that they are participating in.
- iOS 5.0+
- macOS 10.8+
- tvOS 9.0+
To show a turn-based matching user interface, first allocate and initialize a
GKMatch object that describes the desired match. Then, use the match request to initialize a new
GKTurn object. Set the view controller’s delegate, present the view controller, and wait for the delegate to be called. The view controller’s delegate is notified when the matchmaking process is completed or canceled. Once the delegate is called, dismiss the view controller.
In iOS, you present and dismiss the view controller from another view controller in your game, using the methods provided by the
UIView class. In macOS, you use the
GKDialog class to present and dismiss the view controller. Listing 1 shows a typical implementation.