查看: 2207|回复: 4
打印 上一主题 下一主题

[其他] 移动设备上的网络操作

[复制链接]

2722

主题

42

听众

3万

积分

资深设计师

Rank: 7Rank: 7Rank: 7

纳金币
38266
精华
111

最佳新人 活跃会员 热心会员 灌水之王 突出贡献

跳转到指定楼层
楼主
发表于 2014-6-24 09:03:05 |只看该作者 |倒序浏览
iOS and Android
Networking for mobile devices (iOS / Android)


移动设备的网络操作(iOS/Android)
The Unity iOS/Android Networking engine is fully compatible with networking for desktop devices, so your existing networking code should work on iOS/Android devices. However, you may want to re-engineer your code if it is mainly to be used with Wi-Fi or cellular networks. Moreover, depending on the mobile, the networking chip may also be the bottleneck since pings between mobile devices (or between the mobile device and the desktop) are about 40-60 ms, even in high performance Wi-Fi networks.
Unity的iOS/Android网络操作引擎完全兼容桌面设备的网络操作,所以你的已经存在的网络操作代码可以工作在iOS/Android设备上。不过,如果其主要用于Wi-Fi或蜂窝网络你可能想要重新设计你的代码。再有,取决于移动的情况,在移动设备之间(或是在移动设备和桌面设备之间)ping值有大概40-60毫秒,即使是在高性能的Wi-Fi网络上,网络操作芯片也可能成为瓶颈。

Using Networking you can create a game that can be played simultaneously from desktop and iOS over Wi-Fi or cellular networks. In the latter case, your game server should have a public IP address (accessible through the internet).
使用网络操作你能够创建可以在桌面上和使用Wi-Fi或蜂窝网络的iOS上同时玩的游戏。在后面的情况下,你的服务器必须有公网IP地址(通过互联网访问)。
Note: EDGE / 3G data connections go to sleep very quickly when no data is sent. Thus sometimes you may need to "wake-up" networking. Just make the WWW class connect to your site (and yield until it finishes) before making the Unity networking connection..

注意:EDGE/3G数据连接在没有数据发送的时候会很快进入睡眠状态。因此有时候你可能需要"唤醒"网络操作。仅需要在让Unity网络操作连接之前使用WWW类连接到你的站点(并且切出[yield]直到它结束)。
分享到: QQ好友和群QQ好友和群 腾讯微博腾讯微博 腾讯朋友腾讯朋友 微信微信
转播转播0 分享淘帖0 收藏收藏0 支持支持0 反对反对0
回复

使用道具 举报

0

主题

1

听众

1209

积分

助理设计师

Rank: 4

纳金币
82
精华
0
沙发
发表于 2014-6-24 09:04:18 |只看该作者
.....这是随便翻译一段文章的节奏吗
回复

使用道具 举报

hyui    

1

主题

2

听众

6671

积分

高级设计师

Rank: 6Rank: 6

纳金币
2715
精华
0

最佳新人 活跃会员 热心会员 灌水之王 突出贡献

板凳
发表于 2014-6-24 17:44:00 |只看该作者
Good to know!
回复

使用道具 举报

wucnj    

1

主题

1

听众

3160

积分

中级设计师

Rank: 5Rank: 5

纳金币
1065
精华
0

最佳新人 活跃会员 热心会员 灌水之王 突出贡献

地板
发表于 2014-6-25 09:21:41 |只看该作者
感谢分享!!!
回复

使用道具 举报

0

主题

1

听众

170

积分

设计实习生

Rank: 2

纳金币
77
精华
0

最佳新人

5#
发表于 2014-10-16 16:18:03 |只看该作者
支持一個,感謝分享~~
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

关闭

站长推荐上一条 /1 下一条

手机版|纳金网 ( 闽ICP备08008928号

GMT+8, 2024-5-4 00:43 , Processed in 0.082607 second(s), 32 queries .

Powered by Discuz!-创意设计 X2.5

© 2008-2019 Narkii Inc.

回顶部