I have a GKTurnBasedMatch named currentMatch, and I would like to know how to get the name of the player who plays after the player that is currently playing.
Thanks!
NSMutableArray *playerIDs = [NSMutableArray arrayWithCapacity:match.participants.count];
for (GKTurnBasedParticipant *part in match.participants) {
if([part.playerID isKindOfClass:[NSString class]]){
[playerIDs addObject:part.playerID];
}
}
[GKPlayer loadPlayersForIdentifiers:playerIDs withCompletionHandler:^(NSArray *players, NSError *error) {
for (GKPlayer *player in players) {
//get the aliases
}
}];
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With