【问题标题】:Google Play Saved Games Android: result of Games.Snapshots.open()/resolveConflict() frequently has status 16Google Play Saved Games Android:Games.Snapshots.open()/resolveConflict() 的结果经常处于状态 16
【发布时间】:2015-11-19 17:45:07
【问题描述】:

方法Games.Snapshots.open()Games.Snapshots.resolveConflict()(也许还有其他方法,到目前为止还没有检查过)有时(即,并非总是,但经常)返回结果,状态码等于16

GamesStatusCodes documentation 中没有对 16 的解释,Snapshots documentation 本身也没有。我尝试在 Android Studio 中查看GamesStatusCodes,但目前只有 0 到 15 以及 2000 及以上的代码。 GamesStatusCodes.getStatusString 也不知道 16 并输出 Status code (16) not found!

那么 16 究竟是什么意思,是什么导致它出现,我应该如何在我的代码中处理它?还是我只是错过了什么?

【问题讨论】:

  • 我的猜测 - 但可能存在连接问题,因为 16 也是 API_UNAVAILABLE?或CommonStatusCodes.Canceled
  • @ClaytonWilkinson 今天这个问题完全消失了(没有任何代码更改)。所以你可能是对的,那只是一个连接问题。

标签: java android google-play-games


【解决方案1】:

我发现CommonStatusCodes中找到了16,意思是CANCELED

由于客户端断开连接或cancel(),结果被取消。

https://developers.google.com/android/reference/com/google/android/gms/common/api/CommonStatusCodes

【讨论】:

    猜你喜欢
    • 2019-06-15
    • 2016-11-16
    • 1970-01-01
    • 2015-12-25
    • 1970-01-01
    • 1970-01-01
    • 2015-10-29
    • 2014-04-10
    • 1970-01-01
    相关资源
    最近更新 更多