---
title: "init(invite:)"
framework: gamekit
role: symbol
role_heading: Initializer
path: "gamekit/gkmatchmakerviewcontroller/init(invite:)"
---

# init(invite:)

Creates a matchmaker view controller to present to a player who accepts an invitation.

## Declaration

```swift
init?(invite: GKInvite)
```

## Parameters

- `invite`: The invitation that the player accepts.

## Return Value

Return Value An initialized matchmaker view controller object. If an error occurs, returns nil.

## Discussion

Discussion The interface shows the status of the other players accepting and declining their invitations until the game starts.

## See Also

### Creating and configuring the view controller

- [init(matchRequest:)](gamekit/gkmatchmakerviewcontroller/init(matchrequest:).md)
- [matchRequest](gamekit/gkmatchmakerviewcontroller/matchrequest.md)
- [canStartWithMinimumPlayers](gamekit/gkmatchmakerviewcontroller/canstartwithminimumplayers.md)
- [matchmakingMode](gamekit/gkmatchmakerviewcontroller/matchmakingmode.md)
- [GKMatchmakingMode](gamekit/gkmatchmakingmode.md)
