spritekit-game

spritekit-game is a skill for Claude Code, Codex from Abdullah4AI/apple-developer-toolkit. It costs 52 tokens per session (2,358 once invoked), scanned A, original, MIT.

A guide to building two-dimensional games with Apple’s SpriteKit framework, including scenes, physics, sound, particles, and game controls.

In plain words
What is it for?
Use it for arcade games, puzzles, platformers, shooters, racing games, and other 2D games in SwiftUI apps.
Why use it?
It provides the expected structure for a 2D game and avoids using ordinary app views for systems that belong in a game engine.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one. Also seen: positional $N argument.

Good fit Use it for arcade games, puzzles, platformers, shooters, racing games, and other 2D games in SwiftUI apps.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/abdullah4ai/apple-developer-toolkit/spritekit-game
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add Abdullah4AI/apple-developer-toolkit --skill spritekit-game
Clone the repo
git clone --depth 1 https://github.com/Abdullah4AI/apple-developer-toolkit

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for spritekit-game

README.md
[![agentmods](https://agentmods.dev/badge/skills/abdullah4ai/apple-developer-toolkit/spritekit-game.svg)](https://agentmods.dev/skills/abdullah4ai/apple-developer-toolkit/spritekit-game)
Your own site
<a href="https://agentmods.dev/skills/abdullah4ai/apple-developer-toolkit/spritekit-game"><img src="https://agentmods.dev/badge/skills/abdullah4ai/apple-developer-toolkit/spritekit-game.svg" alt="Measured on agentmods" height="20"></a>
Per session 52 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,358 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00052 $0.02358
Opus 5 $0.00026 $0.01179
Sonnet 5 $0.00010 $0.00472
Haiku 4.5 $0.00005 $0.00236

Measured 4d ago against content hash 8c9575ba4f70, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-08, from the pricing page.

Security

Grade A, and why

spritekit-game scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 4d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

swiftship/internal/skills/data/features/spritekit-game/SKILL.md · 241 lines

How it starts

The opening of the file, as written. The whole thing — 241 lines — stays where its author put it; the contents beside it link to each section on GitHub.

SpriteKit 2D Game Development

This skill is for 2D games only. For 3D games (racing, bowling, board games, marble maze, tower defense, 3D sports), load the scenekit-game skill instead.

ARCHITECTURE OVERRIDE: 2D games use SpriteKit (SKScene + SpriteView), NOT plain SwiftUI views with timers or Canvas. The standard @main App → RootView → MainView pattern still applies, but MainView hosts a SpriteView instead of standard SwiftUI content. AppTheme rules apply to SwiftUI parts (menus, overlays) but NOT to SpriteKit scene internals where you use SKColor, SKLabelNode fonts, etc. directly.

Also load the game-assets skill for downloading sprites and textures via nw_download_asset.

SpriteView — SwiftUI Bridge

import SpriteKit
import SwiftUI

struct GameView: View {
    @State var gameState = GameState()

    var body: some View {
        ZStack {
            SpriteView(scene: makeScene(), isPaused: gameState.isPaused)
                .ignoresSafeArea()

            // SwiftUI overlays for HUD, menus (use AppTheme here)
            if gameState.isPaused {
                PauseMenuView(gameState: gameState)
            }
        }
    }

    private func makeScene() -> GameScene {
        let scene = GameScene(size: UIScreen.main.bounds.size)
        scene.scaleMode = .resizeFill
        scene.gameState = gameState
        return scene
    }
}

Rules:

  • Use .scaleMode = .resizeFill so the scene adapts to actual view size
  • Pass data between SwiftUI and SpriteKit via @Observable game state objects
  • SwiftUI overlays (menus, HUD, pause) sit in a ZStack above SpriteView
  • Use SpriteView(scene:, isPaused:) to control pause from SwiftUI
  • SwiftUI parts use AppTheme. SpriteKit scene internals use SKColor/SKLabelNode directly.

Scene Architecture

Layer-based node hierarchy — create in didMove(to:):

SKScene (GameScene)
├── backgroundLayer (SKNode) — z: -100
├── gameplayLayer (SKNode)  — z: 0
└── hudLayer (SKNode)       — z: 100

Read the full file on GitHub · 241 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 4d ago First seen · 241 lines · 52 tokens per session scan A 8c9575ba4f70

Subscribe to this mod's changes

spritekit-game is a skill published in the GitHub repository Abdullah4AI/apple-developer-toolkit (10 stars, last pushed yesterday), licensed MIT. It adds 52 tokens to every session and 2,358 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.

Related

Other skills, from other repositories

sceneview-ios

Build 3D and AR apps on Apple platforms (iOS, macOS, visionOS) with SceneViewSwift — the SwiftUI wrapper around RealityKit. Use whenever the user asks for "3D in SwiftUI", "AR with ARKit in SwiftUI", a model viewer for iOS, or any Apple-platform 3D/AR app where the dependency is the SceneViewSwift Swift Package from…

sceneview/sceneview · 148 tokens

sceneview

Build 3D and AR apps with the SceneView SDK in Jetpack Compose, SwiftUI (iOS/macOS/visionOS via SceneViewSwift), Web (Filament.js), Flutter and React Native. Use whenever the user asks for "3D in Compose", "AR with ARCore in Compose", a model viewer, or any cross-platform 3D/AR app where the dependency is…

sceneview/sceneview · 156 tokens

build-mobile-threejs-games

Build, tune, or test a Three.js game for mobile web. Use for touch movement, action controls, target selection, touch inventory, safe areas, portrait/landscape layouts, responsive HUD, battery/performance budgets, and real mobile browser QA.

MengTo/Skills · 57 tokens

building-mobile-game

Build mobile games and game-like interactive experiences in React Native and Expo. Use when Codex is creating or refactoring arcade, puzzle, casual, action, physics-based, or animation-heavy gameplay, including Expo game setup with the with-reanimated template, sprite-sheet generation and extraction, frame-based…

Intelligent-Internet/ii-agent · 91 tokens

mobile-development

Use when targeting Android/iOS — export and signing, permissions, plugins, in-app purchases, ads, app lifecycle, device features, and mobile performance.

jame581/GodotPrompter · 33 tokens

hz-new-project-creation

Scaffolds new Meta Quest and Horizon OS projects with recommended settings for Unity, Unreal, Android/Spatial SDK, or WebXR. Use when creating a new Quest app from scratch.

meta-quest/agentic-tools · 43 tokens