iOS Game Center Implementation

Game center is incorporated with Apple Inc. to enlarge user experience on gaming application in iOS devices. Game center fulfills the user expectation like real time online games, scores, ranks and challenges with friends. Initially Game center announced in 2010 supported only iOS 4 and above, later on Apple added more features on game center. On 2011 Apple integrated turn based feature on game kit framework supported iOS 5 and above. Now the game center is extended to support on Mac OS X and newly launched tvOS by Apple Inc. If you want to develop and make impact on your game, integrate game center features.

Before implementation you need to decide what kind of game you are willing to develop and which game mechanics to use on gameplay.  You should keep in mind the features and limitation of game center.

Game center Features:

Game center provides large number of features; player can send invite for new friends by searching name and email id. Game center allows creating multiplayer online game with friends and auto player selection form the game center. Game center provides the dashboard on iTunes connect enables the game center components leaderboard and achievements points to compare with friends and other players around the world. Game center given following feature to interact with player:

Leaderboards – shows players level or ranking and how they are playing game compared with friends and other players in game center. You need to create leaderboard on iTunes connect by providing scores, method of priority and languages. ITunes connect also provides leaderboard set to organize the number of leaderboards.

Achievements – provides credits and feedback of game play. You also need to create achievement on iTunes connect by providing point for every achievements and languages with messages. 1000 points are provides for every game from game center. 

Challenges – provides players can challenge with their friends to defeat with scores. But it doesn’t configured n iTunes connect.

Real-time matches - the players are connected to Game Center by each other at a time. The matches are live participating players and live game play to opponent. The major advantage of real time game is, it is simple to implement the game kit and game center provides support. It easy to find player who are joined in real time to play game. The game is high level networking interface that lets disconnect or makes many problem of low networking access. The game kit also provides voice chat during game play. The following methods are used to implement real time game play 

GKMatchRequest

GKMatchmaker

GKInvite

GKMatchmakerViewController

GKMatch

GKVoiceChat

Turn-based matches - the players are connected to game center but not at a time. It connected to game center using store and forward approach. The game play could be a turn by turn between players. Player can make their turn any time until match ends and also only one player will be able to make changes to game play at a time. Turn based matches provides additional features like exchanges these allows between two or more players and can interact if it is not their turn. Implementation turn based matches follows in a game player list, match data; match details are stored in game center with match id. The following methods are used to implement turn based game play.

GKTurnBasedMatch

GKMatchRequest

GKTurnBasedParticipant

GKTurnBasedMatchmakerViewController

GKTurnBasedEventHandler

GKTurnBasedEventListener

Game center integration must follow three steps:

Step 1

 The developers must create a new app record on iTunes connect. You need to enable game center feature. If you require leaderboard and achievements you need to create leaderboard and achievements on iTunes connect.

Step 2

You need to added Game kit framework and game center libraries in your project.

Step 3

You need to authenticate local play first to access game center feature in you project. Game center Player authentication happen after game launched to foreground.

Game center common issues on iOS 9:

  • Apple now launched game center without sandbox environment to test the game center feature on iOS 9 and above. Before it handled sandbox environment for developers to test. Now it’s easy to test in live environment. Meanwhile on iOS 9 devices are facing some common issues of game center
  • Local Player authentication is some times failed, to fix this just restart the app, the authentication working correctly.
  • Match Invite notification didn’t receive to opponent player.
  • Match Turn update didn’t happened for some time and also match create with invalid participants.
  • To fix game center issues on iOS9, you need to enable game center feature in iTunes connect and also its just temporary solution who are not access game center while developing submit app to review team with limited feature, once we got approval all the features are working and it makes easy to develop.

App Store Review Guidelines - Game Center app store review guideline by Apple:

1. Apps that display any Player ID to end users or any third party will be rejected.

2. Apps that use Player IDs for any use other than as approved by the Game Center terms will be rejected.

3. Developers that attempt to reverse lookup, trace, relate, associate, mine, harvest, or otherwise exploit Player IDs, aliases, or other information obtained through Game Center will be removed from the iOS Developer Program.

4. Game Center information, such as Leaderboard scores, may only be used in Apps approved for use with Game Center

5. Apps that use the Game Center service to send unsolicited messages, or for the purpose of phishing or spamming will be rejected.

6. Apps that excessively use the network capacity or bandwidth of Game Center will be rejected.

7. Apps that transmit viruses, files, computer code, or programs that may harm or disrupt the normal operation of the Game Center service will be rejected.

Those who are interested to develop game center application and iOS application development services, contact us now!