I am working on an iOS game with GKSession and GKPeerPickerController. I am finding that the process of connecting two iOS devices is slow and unreliable, even if they are right next to each other. Let's call my devices "device A" and "device B."
Here is what typically happens:
On each device, I hit my app's connect button. Each device then shows the "iPads, iPhones, or iPod touches" window.
Usually pretty quickly, the two devices each notice that the other exists.
I then tell one of the devices (say device A) to connect to the other.
Pretty quickly, device B's window says that device A is not available.
This is where it gets annoying. After a period of time ranging from about 1 second to never, a window pops up on device B saying that device A wants to connect, and asking device B whether or not it wants to accept the connection.
If the above window does pop up, everything proceeds normally. But this sometimes takes a long time, and sometimes does not happen at all.
I have three devices, and I have similar problems no matter which two I am using.
Is there anything I can do about this?
My connection method is pretty straightforward:
-(void) findPeerPickerOpponents {
GKPeerPickerController *picker;
picker = [[GKPeerPickerController alloc] init];
picker.delegate = self;
[picker show];
[self.connectionDelegate disableIdleTimer];
}