ibrews/apple-platform-skills/gamekit-multiplayer
Claude Code and agent skill by ibrews/apple-platform-skills
- community
Checking that the SKILL.md file is still in the repository.
GameKit real-time and turn-based multiplayer for iOS and visionOS. Use when implementing GKMatch matchmaking, GKLocalPlayer authentication, real-time data sync, or turn-based game logic using Apple's Game Center infrastructure.
Install
npx vskill@latest install ibrews/apple-platform-skills/gamekit-multiplayerSKILL.md
GameKit Multiplayer
Authentication First — Always
Nothing in GameKit works until GKLocalPlayer is authenticated. Call this at app launch, before any matchmaking UI:
Common pitfall: calling findMatch before auth completes → silent failure, no error callback.
GKMatchmaker vs GKMatchmakerViewController
| GKMatchmaker | GKMatchmakerViewController | ||
|---|---|---|---|
| UI | Your own custom UI | Apple's built-in Game Center UI | |
| Use when | Full control, invite-only flows | Quick integration |
Real-time vs Turn-based
GKMatch (real-time):
- All players online simultaneously
- Low-latency continuous sync (positions, inputs)
- Action games, racing, shooters
GKTurnBasedMatch:
- Players take turns asynchronously (may be hours apart)
- Apple persists game state on their servers
- Strategy games, board games, word games
Sending & Receiving Data (Real-time)
Player Connect / Disconnect
match.expectedPlayerCount starts at (minPlayers - 1) and decrements as players join. Start the game only when it reaches 0.
Sandbox vs Production
- Test accounts: create sandbox Apple IDs in App Store Connect → Users and Access → Sandbox
- Sandbox and production Game Center are completely separate — leaderboards, matches, and friends don't cross
- Enable on device: Settings → Developer → Enable Sandbox Game Center (Xcode scheme also works)
- Always test with two sandbox accounts to catch auth edge cases
Common Pitfalls
| Pitfall | Fix | |
|---|---|---|
| Matchmaking before auth | Set authenticateHandler at launch; wait for isAuthenticated callback | |
| UI updates in delegate | Wrap all UI in DispatchQueue.main.async | |
| Starting too early | Wait for match.expectedPlayerCount == 0 | |
| Match object deallocated | Keep strong var match: GKMatch? reference | |
didFailWithError not implemented | Network errors only surface here — implement it | |
| Turn-based state lost | Call match.saveCurrentTurn(withMatch:completionHandler:) before ending turn |
Security
- Security scanPassed, 100 of 100Pattern checks on the skill's files.
- Model reviewNot runA model review is scheduled for the next rescan.
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckinggamekit-multiplayer/SKILL.md
Popularity
- Repository stars
- 2
- Repository forks
- 1
- 7-day trend score
- 0
Stars and forks are for the whole GitHub repository, not this skill alone. Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/ibrews/apple-platform-skills/gamekit-multiplayer)