The GKInviteEventListener Protocol contains the following method that must be implemented:
-(void)player:(GKPlayer *)player didRequestMatchWithPlayers:(NSArray *)playerIDsToInvite
But it is unclear how to trigger this method. The documentation says:
Called when the local player starts a match with another player from Game Center. (required)
When this method is called, the game is launched from Game Center and starts the matchmaking process.
In practice, there doesn't seem to be a way to "launch" games from the "Game Center" app. So how does one trigger this method?
Also, if one invites players from within the game (not the game center app), the corresponding method player:didAcceptInvite
: is triggered on the "invitees" device, but player:didRequestMatchWithPlayers
is not triggered on the inviters device (there doesn't seem to be a reason to, anyway.)
EDIT: From the game center app, I can choose to "play" my game, but there doesn't seem to be a way to invite other players to play my game.
Also keep in mind - it seems that there may be some configuration required to get game center to recognise my app as multiplayer. I want instructions on how to get game center to recognise my game as multiplayer so i can invite people from the app.
I have already configured it in iTunes connect, and can successfully matchmake or invite other players through my app. I just can't do it through the game center app, since it doesn't give me the option.
My app has not been released yet, and currently there is just one version. So under multiplayer compatibility this is the only one listed.
The secret is "...", but only after the right sequence of menu navigations!
If you go directly to the game and click ..., you can "play" the game, but are not given the option to invite anyone.