Game Center Match Event Listener not receiving any events

I am testing a turn based multiplayer game in iOS in developer mode with sandbox Apple accounts. I can already play the game and normally end and begin turns, but I can’t receive “playerTurn”, “matchEnded” and “invitationReceived” events.

Is it probably something wrong in the code or is this a problem with sandbox testing? I tried multiple times since yesterday.

Thanks

local gn = require "gameNetwork" gn.request( "setEventListener", { listener = function(event) print( "This will never be printed" ) if event.type == "playerTurn" then print( "Also never gonna be printed" ) end end } )

Hi @lmgualandi,

Unfortunately, this kind of thing has been historically difficult to diagnose. I’ve been through a few support cases on it, and it comes down to many varying factors: the version of iOS, how you’ve set up Game Center for your app, and more. The starting point would be to determine exactly which versions of iOS you’re testing with, and that those devices have Game Center set up exactly as required for testing multiplayer.

Best regards,

Brent

Thanks for the reply. I’ll do some further attempts

@lmgualandi,

Check out the Corona SDK GameKit plugin that I wrote, it has all the Apple Game Center turn-based and real-time game features of iOS 7 and I even added some polling methods to pull data from missed events: https://forums.coronalabs.com/topic/63791-gamekit/

Link to the GKTester appsource is now up on github, which contains Lua code examples for iOS Game Center Achievements, Challenges, Leaderboards, Real-Time and Turn-Based Games.

Sorry for the delay. I still didn’t figured it out. I’m never receiving the playerTurn event.

All my devices have the latest version of iOS(9.3.3). I also tested with normal accounts.

What exactly do you mean with “Game Center set up exactly as required for testing multiplayer”?

Another question: what is the correct way to test Game Center multiplayer? With sandbox or normal accounts?

Hi @lmgualandi,

Unfortunately, this kind of thing has been historically difficult to diagnose. I’ve been through a few support cases on it, and it comes down to many varying factors: the version of iOS, how you’ve set up Game Center for your app, and more. The starting point would be to determine exactly which versions of iOS you’re testing with, and that those devices have Game Center set up exactly as required for testing multiplayer.

Best regards,

Brent

Thanks for the reply. I’ll do some further attempts

@lmgualandi,

Check out the Corona SDK GameKit plugin that I wrote, it has all the Apple Game Center turn-based and real-time game features of iOS 7 and I even added some polling methods to pull data from missed events: https://forums.coronalabs.com/topic/63791-gamekit/

Link to the GKTester appsource is now up on github, which contains Lua code examples for iOS Game Center Achievements, Challenges, Leaderboards, Real-Time and Turn-Based Games.

Sorry for the delay. I still didn’t figured it out. I’m never receiving the playerTurn event.

All my devices have the latest version of iOS(9.3.3). I also tested with normal accounts.

What exactly do you mean with “Game Center set up exactly as required for testing multiplayer”?

Another question: what is the correct way to test Game Center multiplayer? With sandbox or normal accounts?