使用“Google Play游戏服务”玩游戏时突然断开连接

3
我会尽力为您翻译,以下是需要翻译的内容:

我按照谷歌指南 (https://developers.google.com/games/services/android/multiplayer) 实现了游戏多人模式。看起来一切都工作正常,但是“有时候”连接突然丢失,并且事件(onLeftRoom或onDisconnectedFromRoom)不会在发生后执行。

如果我查看logcat,我可以看到一些相关信息:

09-19 15:50:08.623: I/libjingle(10434): void buzz::PresencePushTask::HandlePresence(const buzz::Jid&, const buzz::XmlElement*): Received directed presence :0x4dxicadq3fv30u0iy8gcj9yz@public.talk.google.com/games_andr34DE8388
09-19 15:50:08.623: E/DataConnectionManager(10434): Received directed presence of type 'unavailable' from peer.
09-19 15:50:08.623: I/libjingle(10434): Removing from roster: 0x4dxicadq3fv30u0iy8gcj9yz@public.talk.google.com/games_andr34DE8388
09-19 15:50:08.683: W/libjingle(10434): Warning(libjingleclient.cpp:1183): void gtalk::LibjingleClient::TerminateAllCalls_w(): Terminating call for session:1464668934
09-19 15:50:08.693: I/DataConnectionManager(10434): onConnectionResult called for sessionId: 1464668934 result: false
09-19 15:50:08.693: D/rtmp:LibjingleEventHandler(10434): [libjingleHandler] handleMessage(CALL_STATE_CHANGED): for sessionId: 1464668934 new state=12
09-19 15:50:08.693: W/libjingle(10434): Warning(callregistry.cpp:27): void games_rtmp::CallRegistry::UnregisterCall(const string&, const string&): Attempting to erase non-existent session:1464668934
09-19 15:50:08.693: E/DataConnectionManager(10434): tearDown() called when network is NOT ready for match !
09-19 15:50:08.693: I/libjingle(10434): worker_thread:0x62acd7d8 initialized=1
09-19 15:50:08.693: I/libjingle(10434): Waiting for a reply.
09-19 15:50:08.693: I/libjingle(10434): Channel disabled
09-19 15:50:08.693: I/libjingle(10434): Changing data state, recv=0 send=0
09-19 15:50:08.693: I/libjingle(10434): Destroyed channel
09-19 15:50:08.693: I/libjingle(10434): Waiting for a reply.
09-19 15:50:08.703: I/DataConnectionManager(10434): onConnectionResult called for sessionId: 1464668934 result: false
09-19 15:50:08.703: E/DataConnectionManager(10434): Could not find JID for session ID 1464668934
09-19 15:50:08.703: D/rtmp:LibjingleEventHandler(10434): [libjingleHandler] handleMessage(CALL_STATE_CHANGED): for sessionId: 1464668934 new state=15
09-19 15:50:08.703: I/libjingle(10434): Waiting for a reply.
09-19 15:50:08.703: I/libjingle(10434): Waiting for a reply.
09-19 15:50:08.703: I/libjingle(10434): worker_thread:0x62acd7d8 initialized=1
09-19 15:50:08.703: I/libjingle(10434): Waiting for a reply.
09-19 15:50:08.703: I/libjingle(10434): SSL Cleanup

我对这个问题感到非常困惑,有人可以帮帮我吗?


我在我的游戏中看到类似的消息。我使用最新的 GPG v1.4.1,并得到了这个:https://github.com/playgameservices/android-basic-samples/issues/155 - Bram
3个回答

2

我已经更新了Google Play服务库,现在它可以正常使用了。


1

我遇到了同样的问题。我正在测试一段两天前正常运行的代码,所以我认为这是由于谷歌引起的。稍后再试一下。


错误仍然出现,我已经尝试了所有的方法。我刚刚向Google支持团队发送了一条消息... - Carlos
有什么新消息吗?你知道在哪里可以了解更多关于它的信息吗? - Sergio Viudes

1
这几天甚至在wifi上也更频繁地出现了这种情况。我想你的代码没问题,这可能是与Google相关的问题,会自行解决。

网页内容由stack overflow 提供, 点击上面的
可以查看英文原文,
原文链接