在GKTurnBasedMatch中更新matchData而不结束转弯 [英] Updating the matchData in a GKTurnBasedMatch without ending the turn

查看:214
本文介绍了在GKTurnBasedMatch中更新matchData而不结束转弯的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

似乎GameKit每次从Game Center服务器加载GKTurnBasedMatch时仅允许更新GKTurnBasedMatch一次.还有另一种更新matchData属性的方法吗?

It seems that GameKit only allows GKTurnBasedMatch to be updated once per time that GKTurnBasedMatch is loaded from the Game Center servers. Is there an other way to update the matchData property?

推荐答案

以下方法已添加到iOS 6.0中的GKTurnBasedMatch中,并且可以满足您的需要:

The following method was added to GKTurnBasedMatch in iOS 6.0 and will do what you need:

- (void)saveCurrentTurnWithMatchData:(NSData *)matchData
                   completionHandler:(void (^)(NSError *error))completionHandler

在不将游戏推进到其他玩家的情况下更新比赛数据"

"Update the match data without advancing the game to another player"

这篇关于在GKTurnBasedMatch中更新matchData而不结束转弯的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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