开发者

Connecting a client to a server using GKSession

开发者 https://www.devze.com 2023-01-23 19:56 出处:网络
What is the proper way to connect two apps using GKSession, where one acts as a GKSessionModeClient and one as a GKSessionModeServer?

What is the proper way to connect two apps using GKSession, where one acts as a GKSessionModeClient and one as a GKSessionModeServer?

For the server, does it start listening after initWithSessionID:displayName:sessionMode: is called and available is set to YES?

How do I search for the server with the client? After I initialize a GKSession with the same session ID, I'm not sure how to look for the server and connect to开发者_如何学Python it.


I figured out the problem. The client GKSession also needs available set to YES in order to begin searching. The GKSessionDelegate will then be called.

0

精彩评论

暂无评论...
验证码 换一张
取 消