Questions tagged [gkmatchmaker]

Class used in GameKit.framework(Game centre programming in iOS6).

The GKMatchmaker class is used to programmatically create matches to other players and to receive match invitations sent by other players.

Complete Class Reference.

52 questions
8
votes
1 answer

iOS Game Center GameKit Programmatic Invite Matchmaking

I'm trying to implement a real-time multiplayer game with a custom UI (no GKMatchMakerViewController). I'm using startBrowsingForNearbyPlayersWithReachableHandler: ^(NSString *playerID, BOOL reachable) to find a local player, and then initiating a…
Jim
  • 181
  • 2
  • 9
8
votes
1 answer

ios: programmatically ask for Game Center sign-in?

I have a simple question, but I’ve looked through Apple’s documentation and done some searching and I can’t find the answer to it. Is it possible to programmatically pull up Game Center’s sign-in view? I have a UIButton that requires Game Center,…
anders
  • 4,168
  • 2
  • 23
  • 31
7
votes
2 answers

Handling cancel in GKMatchmakerviewcontroller

I am making a multiplayer feature to a game I made. Everything is working, except when I am in matchmaking and both players are connected, if one person hits the "Cancel" button the other device gets no notice of the canceling. On the other device…
Wyetro
  • 8,439
  • 9
  • 46
  • 64
6
votes
2 answers

Only use Automatch in Gamecenter

How do you remove the invite friend button from a GKMatchmakerViewController? When printing all of the subviews in it I only see the navigation bar. I am presenting it like this: GKMatchmakerViewController *mmvc = [[GKMatchmakerViewController alloc]…
Wyetro
  • 8,439
  • 9
  • 46
  • 64
4
votes
1 answer

Game Center inviting friends programmatically

I'm facing difficulty inviting a friend to the match. GKMatchRequest *request = [[[GKMatchRequest alloc] init] autorelease]; request.minPlayers = 2; request.maxPlayers = 2; request.playersToInvite = [NSArray arrayWithObjects:…
Chris Rutkowski
  • 1,774
  • 1
  • 26
  • 36
4
votes
0 answers

Implement my own a custom GKTurnBasedMatchmakerViewController

I'm sure there are questions similar to this, but I couldn't find an example. I'm trying to recreate the apple GKTurnBasedMatchmakerViewController for my turn based game with my own custom interface for my turn based iphone game. I'm having…
4
votes
1 answer

Error message when building default iOS solution in with monogame

Does anybody know why I get the following error message when I try to build the default "MonoGame.Framework.iOS.sln" on Monotouch? And how I can fix this? : on line 468 of the Guide source file (From…
Sonia Brami
  • 127
  • 1
  • 1
  • 10
3
votes
0 answers

Swift - GKMatchDelegate

I am quite new to Swift, started developing my own app recently. I've been trying to implement the Game Center multiplayer. The current structure of my project is (standard game center structure): GameViewController - UIViewController,…
3
votes
0 answers

How do you implement shared GKMatchmaker's findMatchForRequest correctly (so GKMatch.expectedPlayerCount == 0)?

When switching to GKMatchmaker from MatchmakerViewController my two sandbox game center accounts running on separate devices (both iPhone 5s) no longer connect into the same match. Both show expectedPlayerCount still above 0. I followed the…
Tim Cron
  • 51
  • 3
2
votes
1 answer

Encountering runtime error " attempt to insert nil object "

I am trying to write a simple multiplayers Swift program using Xcode 7 beta 5. I encountered the following error at runtime: [__NSPlaceholderArray initWithObjects:count:]: attempt to insert nil object from objects[0]' *** First throw call stack And…
chihoxtra
  • 31
  • 2
2
votes
1 answer

EXE_BAD_BADACCESS trying to access GKMatch?

The Problem In Brief Trying to play with a friend in real-time using gamecenter causes a crash during gameplay Project Details I am using gamecenter with cocos2dx I am using the SANDBOX mode: Both accounts being tested are in sandbox mode 2 Ipads…
Striker
  • 507
  • 4
  • 11
2
votes
3 answers

When would GKMatchRequest be 'invalid'?

Occasionally, but not rarely, the findMatchForRequest:withCompletionHandler: returns with error 13 or GKErrorMatchRequestInvalid: "The requested operation could not be completed because the match request is invalid." The documentation only…
Blaz
  • 3,548
  • 5
  • 26
  • 40
2
votes
2 answers

startBrowsingForNearbyPlayersWithHandler() in iOS 8 in Swift

I'm currently making a 2-player strategy board game in Swift and need to connect two iPads over local WiFi or Bluetooth. No matter what I've tried today, I can't get them to detect each other (I've tried over local WiFi and Bluetooth). Here is my…
Chuck Smith
  • 2,101
  • 3
  • 16
  • 21
2
votes
1 answer

GameKit Match - invite friends between iOS5 and iOS6

I'm trying to implement Game Center invites in a 2-person realtime game. Since invites are not supported in the simulator, I'm testing this on one device running iOS5 and a second one running iOS6 (this is done on purpose). If I'm using the…
Amiram Stark
  • 2,208
  • 22
  • 32
2
votes
0 answers

Matchmaking invite friend fails instantly when using GKMatchMakerViewController initWithRequest

this is my first question on Stack Overflow, so thanks in advance. I am adding simple 1v1 mutliplayer functionality to my iPhone game, and I am struggling with the Matchmaker functionality. Currently I have a ViewController acting as delegate for…
1
2 3 4