How can you use Xocde debugger when testing Invites?

I understand the simulator cannot be used to send an game Invite to an iPhone. As a result, I have two real iPhones which I am using. How can I see the logging generated from the iPhone that receives the Invite? This iPhone does not currently have the application running when the Invite comes in, so is there a way to have an iPhone connected to the Xcode debugger before the application is even woken up due to receiving an Invite?

Answered by uncletr in 405166022

ok, it just occurred to me I can connect my iPhone-B to the simulator, start my application and then just sit on the main menu screen of my game. I can now use iPhone-A and invite iPhone-B as a "Friend". This will result in all messaging relating to the Invite request being caught by the simulator, since I was connected to the simulator before the invite arrived.

>I understand the simulator cannot be used to send an game Invite to an iPhone.


It can send an invite. It can't receive an invite.

In the simulator, when the GKMatchmakerViewController is displayed, I can select "Invite Friends" and select a player that I played with recently (ie: my iPhone-B). After selecting the user, I then click "send" to send the invite. The GKMatchmakerViewController indicates "Invitation Sent" but then really quickly displays "Failed". The logs indicate "The requested operation could not be completed because local player has not been authenticated." If I use the same simulator to select players randomly, then eveything works, so I know the localPlayer (ie: simulator player) is authorized already. As a result, I still cannot send an invite out using the simulator. Any ideas what sending invites from the simulator does not work?


That being said, I really need to know how to obtain logging from the player who is being sent the invite. Can this be done?

Accepted Answer

ok, it just occurred to me I can connect my iPhone-B to the simulator, start my application and then just sit on the main menu screen of my game. I can now use iPhone-A and invite iPhone-B as a "Friend". This will result in all messaging relating to the Invite request being caught by the simulator, since I was connected to the simulator before the invite arrived.

Just for fyi .... I still cannot send an Invite out from the simulator though.

How can you use Xocde debugger when testing Invites?
 
 
Q