GameKit wifi连接? [英] GameKit wifi connection?

查看:178
本文介绍了GameKit wifi连接?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经读过,从iPhone OS 3.1开始,GameKit支持wifi连接。但文档说明:

I've read that as of iPhone OS 3.1, GameKit supports wifi connections. But the documentation states:


如果您的应用程序配置
对等选择器以允许Internet
连接,那么您的应用程序必须
也解雇同行选择器,
提供自己的接口来配置
互联网连接。

"If your application configures the peer picker to allow Internet connections, your application must also dismiss the peer picker and present its own interface to configure an internet connection."

这仍然有效吗?如果是这样,我如何建立一个可供GK使用的wifi Bonjour会话? (我只对使用本地网络感兴趣。)

Does this still stand? If so, how do I establish a wifi Bonjour session that can be used by GK? (I'm only interested in using the local network.)

推荐答案

您的GKSession对象将通过WiFi自动处理对等体的发现或蓝牙,并找到任何协议上可用的那些。

Your GKSession object will automatically handle the discovery of peers over WiFi or Bluetooth, and find those that are available on either protocol.

该文档说明与蓝牙不同,GKPeerPickerController为其提供启用蓝牙的UI(如果尚未启用) ,GKPeerPickerController没有提供启用wifi的UI,或者选择用户希望使用的网络,你必须自己提供。

The documentation is stating that unlike Bluetooth, for which GKPeerPickerController provides a UI to enable Bluetooth if it's not already enabled, GKPeerPickerController does not provide a UI to enable wifi, or select the network the user wishes to be on, you will have to provide your own.

这篇关于GameKit wifi连接?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆