Skip to content
StringsaeedPublic

About

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

184 Commits

Folders and files

Repository files navigation

PewPew: 30 levels, 3 bosses, one rocket

Download on the App Store

Play it in your browser · check · MIT

PewPew is a neon space shooter for iPhone. Thread a rocket through asteroid fields, minefields, drone swarms, and gravity wells, beat a boss every tenth level, and dive into the black hole.

It's a React Native app with no game engine. Every frame is drawn by WebGPU, the UI animates on Reanimated 4, and the music is synthesized live by React Native Audio API. AI agents wrote the code, then play-tested and profiled it on the iOS Simulator through Argent.

Fighting the Hive boss on level 20 The Warden boss Diving into the black hole The Core boss

The game

  • 30 levels in three tiers, each with its own palette and song. Every difficulty column ramps up and never goes down.
  • 3 bosses. The Warden, the Hive, and the Core each have 2 to 3 phases with their own attack cycles.
  • One finger. Drag anywhere to steer and the rocket fires on its own. The lives you finish with are your stars.
  • Free, offline, private. No account, ads, tracking, or in-app purchases. Progress stays on the device.

How it's built

Layer What it does
react-native-webgpu + TypeGPU Four pipelines with shaders written in TypeScript with TypeGPU and resolved to WGSL at build time (npm run gen:shaders), so the app ships plain WGSL: a procedural nebula and starfield, instanced flat-shaded meshes, additive glow, and a fresnel shield bubble. Instance data goes up in three buffer writes per frame.
Reanimated 4 Score pops, lost lives, boss bars, and panels run on the UI thread. React renders the HUD only when a value on it changes.
React Native Audio API Tracker songs and effects synthesized at runtime from data. The app ships zero audio files.
Argent Agents drove the simulator: they tapped, swiped, read the React tree, profiled, and recorded. They also staged every screenshot and video in the launch kit.
Pure TypeScript sim Fixed 60 Hz step, seeded tracks, and no platform code. It runs the same on the phone, in Node, and in a browser.

The whole JS frame (sim, bot, renderer, audio, and HUD) takes about 3 ms and held 60 fps in a simulator dev build (report). Meshes are generated by a script, so the app bundles no image, model, or audio assets for gameplay.

docs/architecture.md walks through the design: the compiled track, the flat body pool, the loop, the renderer, and the audio engine.

Layout

src/sim/       deterministic simulation: world, step, boss, drones, input, HUD
src/levels.ts  the 30-row level table, validated at import
src/bot.ts     greedyBot, used by AUTO mode and the verifier
src/render/    WebGPU renderer, TypeGPU shaders, generated meshes
src/audio/     synth engine and song data
src/shell/     the frame loop and React hooks (GPU, save, audio lifecycle)
src/ui/        React Native screens and HUD
scripts/       level verifier, mesh generator, song renderer, ramp sweep
website/       pewpew.saeed.sh (Astro), with the real game playable on WebGPU
marketing/     App Store screenshots, preview video, social videos, OG image
.audit/        reports, traces, and captures the agents left while building

Run it

You need Node 22, Xcode, and an iOS Simulator or device. The game uses native modules, so it runs in a development build, not Expo Go.

npm ci
npx expo run:ios

Checks run in CI on every push:

npm run check     # typecheck, unit tests, level verifier, generated-mesh check
npm run verify    # a greedy bot flies all 30 levels; replays must be bit-identical

The website

cd website
npm ci
npm run dev       # http://localhost:4321

The site imports the game's sim, renderer, and synth straight from ../src, so the hero demo is the real game running on your browser's WebGPU. Browsers without WebGPU get a recording instead.

The marketing kit

marketing/ regenerates the store assets from simulator captures. All text is rendered by headless Chromium, and ffmpeg does the compositing.

cd marketing && npm ci
npm run screenshots   # captioned App Store screenshots: 1320x2868, 1206x2622, and iPhone Duo 1398x2034
npm run creative      # iOS 27 header, search result, and universal creative assets
npm run preview       # 886x1920 App Store preview, with the game's own soundtrack
npm run social        # 16:9 and 1:1 launch videos
npm run og            # 1200x630 social card for the site

The screenshot script reads the stills in marketing/raw/ (iPhone Duo outer-display stills in marketing/raw/duo/). The preview and social videos need raw simulator recordings and the rendered soundtrack (npm run render-song). The header of marketing/video/app-preview.sh explains how to capture them.

Credits

Built by Muhammed Saeed with AI agents in Cursor, Claude, GPT, and T3 Code. Thanks to Software Mansion for Reanimated, Audio API, and Argent, and to William Candillon for react-native-webgpu.

PewPew is released under the MIT license. Apple, the Apple logo, iPhone, and App Store are trademarks of Apple Inc.

About

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages