https://github.com/yeahdongcn/night-city-pixel
Pixel-art cyberpunk action RPG in pure vanilla JS โ collect iron, buy chrome, own the streets. Zero deps, all art & music procedural, moddable, AI-agent-friendly. Unofficial fan tribute.
https://github.com/yeahdongcn/night-city-pixel
cyberpunk fable game html5-canvas moddable pixel-art vanilla-js
Last synced: 16 days ago
JSON representation
Pixel-art cyberpunk action RPG in pure vanilla JS โ collect iron, buy chrome, own the streets. Zero deps, all art & music procedural, moddable, AI-agent-friendly. Unofficial fan tribute.
- Host: GitHub
- URL: https://github.com/yeahdongcn/night-city-pixel
- Owner: yeahdongcn
- License: other
- Created: 2026-06-12T05:21:05.000Z (about 1 month ago)
- Default Branch: main
- Last Pushed: 2026-07-07T02:34:35.000Z (17 days ago)
- Last Synced: 2026-07-07T03:07:43.543Z (17 days ago)
- Topics: cyberpunk, fable, game, html5-canvas, moddable, pixel-art, vanilla-js
- Language: JavaScript
- Homepage:
- Size: 909 KB
- Stars: 2
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
- Agents: AGENTS.md
Awesome Lists containing this project
README
๐ NIGHT CITY โ Pixel Edition
Collect iron. Buy chrome. Own the streets.
A pixel-art cyberpunk action RPG that runs entirely in your browser โ
zero dependencies, zero asset files, one neon-soaked city generated from code.
๐ฎ PLAY NOW โ yeahdongcn.github.io โ desktop or phone (twin-stick touch controls appear automatically)

Run a Scav pack over at full speed โ the blood stays on the asphalt, the loot is yours.
## What you do
Pick your V, roll a random starter kit, and work Night City: hunt **bounties**, take down
**cyberpsychos** for one-of-a-kind iconic weapons, crack **gang hideouts** and **loot crates**,
race the Barghest to **Militech airdrops** over Dogtown โ then spend every eddie at the
gun store, the autofixer, and the ripperdoc.
- ๐ซ **39-weapon database** โ power / tech (piercing) / smart (homing) classes, 8 cyberpsycho-only
iconics, a hidden talking pistol, and 4 cyber-arm weapons (Mantis Blades, Gorilla Arms, Monowire, launcher)
- ๐ **12 vehicles** with drift physics, full-body run-over combat, blood decals, and street delivery on **V**
- ๐ฆพ **17 cyberware implants** โ Sandevistan bullet-time, Berserk, Kerenzikov, Optical Camo,
Second Heart, Smart Link, and more, most with 3 upgrade marks
- ๐ **Real stealth** โ enemies have view cones, wall occlusion, suspicion meters, and last-known-position
searches; melee takedowns hit 2.5ร; dive into district flora to vanish from sight
- ๐ข **Enterable buildings** โ GTA-style roof reveal, walk-in shops with vendors, furnished interiors, gang dens
- ๐ง **Random weather** โ clear nights, storms, fog, acid drizzle, smog; fog genuinely shortens enemy vision
- ๐ป **5-station MIDI radio**, joytoys & the CLOUDS dollhouse, six districts with their own gangs and danger โ
ratings
- ๐พ Autosaves to localStorage ยท ๐งฉ **mod API** so players become creators
## Gallery
| | |
|:---:|:---:|
| 
Jack in | 
Choose your V |
| 
Walk-in shops: Wilson's gun racks | 
Jig-Jig Street & the CLOUDS dollhouse |
| 
Militech airdrop inbound over Dogtown | 
Storm over the City Center |
## Run it
```bash
git clone https://github.com/yeahdongcn/night-city-pixel && cd night-city-pixel
./run.sh # serves on http://localhost:8080
# or: python3 -m http.server 8080 ยท or: npx serve . ยท or just open index.html
```
Desktop: keyboard + mouse (click once to enable audio).
**Mobile (iPhone/Android):** touch is auto-detected โ left stick moves/drives, right stick
aims (push past 55% to fire), on-screen buttons handle dash/interact/heal/abilities, and
menus are tap + drag-to-scroll. Landscape recommended; add to home screen for fullscreen.
## Controls
| Key | Action | Key | Action |
|---|---|---|---|
| WASD | Move / drive | Q | OS ability (Sandevistan / Berserk) |
| Mouse + LMB | Aim / fire / swing | F | Optical camo |
| Space | Dash (handbrake in car) | C | MaxDoc heal |
| R | Reload | E | Interact |
| 1/2/3 ยท wheel | Weapon slots | V | Summon / enter / exit vehicle |
| N | Radio dial | TAB | Inventory ยท collections ยท stats |
| M | Mute | ESC | Pause |
## Mods โ players become creators
The game ships with a mod loader: edit **`mods/mods.js`**, refresh, done. Add weapons,
vehicles, cyberware, radio stations, and event hooks โ they appear in the shops, the
collection database, the garage, and on the radio dial. No build step.
Full API + a working sample mod: **[MODDING.md](MODDING.md)**.
## Contributing โ humans *and* AI agents welcome
This game was built almost entirely by an AI coding agent (Claude) pair-programming with a
human director โ so AI-assisted and fully agentic PRs aren't just tolerated here, they're
the house style. Bring your own agent.
- **Agents:** read **[AGENTS.md](AGENTS.md)** first โ project map, invariants, and the rules
that keep saves and determinism intact.
- **Everyone:** `node test/smoke.js` must stay green, keep the zero-dependency /
zero-binary-asset rule (all art and audio are procedural), and bump the `?v=` cache
version in `index.html` when you ship.
- Content additions (weapons/cars/stations) are usually better as **mods**; engine PRs
should come with smoke-test coverage.
## Tech notes
- 640ร360 internal canvas, HiDPI-aware integer scaling (`image-rendering: pixelated`), custom 3ร5 bitmap font.
- 128ร128-tile city pre-rendered to offscreen canvases (deterministic seed so saves stay valid);
per-building fading roof layers for interiors; two-pass entity rendering for correct facade depth.
- WebAudio: every sound synthesized; the radio is one 64-step sequencer driven by station data.
- `node test/smoke.js` โ headless simulation of every system (combat, stealth, shops, driving,
psychos, airdrops, weather, save/load) against stubbed DOM/canvas.
- Debug URLs: `?autostart`, `?demo`, `?charsel`, `?indoor`, `?jigjig`, `?airdrop`, `&wx=storm|fog|acid|โฆ`, `&v=f`.
## License
MIT (see [LICENSE](LICENSE)). **Unofficial fan tribute** inspired by Cyberpunk 2077 โ not
affiliated with or endorsed by CD PROJEKT RED. All code, pixel art, and audio are original;
in-universe names appear in a non-commercial fan context.