Only One Participant ID in onTurnBasedMatchReceived()

喜你入骨 提交于 2019-12-25 02:16:29

问题


When the other player makes a turn, I am successfully receiving an "onTurnBasedMatchReceived()" update, but in the match details there is sometimes only my own participantId. Without knowing the other player's ParticipantId, I cannot do a takeTurn and pass the ID to the other player. Why do I sometimes not get the other player's ID and sometimes I do?


回答1:


If you've auto-matched with a random opponent and not taken the first turn yet, then you will only get one Participant Id. Just pass in null to takeTurn() for the pendingParticipantId field.



来源:https://stackoverflow.com/questions/21767373/only-one-participant-id-in-onturnbasedmatchreceived

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!