Skip to content
levithefirstPublic

About

CADE OPS: a 60-second browser arcade game with a global leaderboard, plain canvas JS plus Vercel functions and Upstash Redis.

Topics

Resources

Stars

1 star

Watchers

0 watching

Forks

Latest commit

 

History

85 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

CADE OPS

Dash. Nerf. Dominate. CADE OPS is a 60-second arcade game for the browser, presented as "CadeMarket presents". You dash through six roaming team leaders (the "Nerfs") to disable them, dodge rugs, and chain near-misses into a degen multiplier. Your best score goes onto a global leaderboard tied to a callsign that can't be changed.

It is plain HTML, CSS and native ES modules on a canvas, with no build step. Five Vercel serverless functions in api/ back the game with Upstash Redis.

HTML5 Canvas JavaScript Vercel Functions Upstash Redis

Note

The repo's homepage, cade-acc.vercel.app, currently returns Vercel DEPLOYMENT_NOT_FOUND, and so does the share URL hard-coded in js/ui.js (cade-ops.vercel.app). Right now there is no live deployment to play.


How to play

Input Action
Mouse, drag (touch), WASD or arrow keys Move
⚡ button Ape Dash. Dash through a team leader to nerf them.
Space or the BURST button Burst, which charges from pumps and close calls
  • A run lasts 60 seconds, and the last 15 seconds are a "meltdown" with heavier spawns.
  • You get 6 lives. Touching a team or a rug without dashing costs one.
  • Grazing hazards builds the degen multiplier, up to ×15.
  • Green pumps pay out multiplied. Collect 3 in a row to fill your energy bar for a speed boost.
  • When the run ends you get a rank, from PAPER HANDS up to ABSOLUTE PSYCHOPATH. You can share it on X, copy the tweet, or save a score card image.

There are five rug types: DUMP, WICK, LIQUIDATION, FAKEOUT and WHALE. The six Nerfs are Steve, gnar, Kosgood, Scotty, Rookmate and Pop Punk, each with its own weapon and combat AI. All tunables live in js/config.js.

Features

  • Permanent callsign. On first visit you pick a callsign of 10–16 characters (letters, numbers, spaces, _ or -). The server stores it against an HttpOnly __Host-cade_player_id cookie, and after that it can't be changed.
  • Global leaderboard. Each registered player gets one entry, holding their best score (Redis ZADD GT). Submissions are idempotent per runId for 24 hours and rate-limited to 5 per IP per minute. Claiming the run and updating the score happen in one atomic Lua script.
  • Resilient submits. The client stores a pending score and retries it after a reload or when you open the leaderboard. The leaderboard waits for any in-flight write before it loads.
  • Aggregate analytics. /api/stats exposes only public-safe totals, such as players online (a 45-second presence lease), sessions, completions, high score and averages. See docs/ANALYTICS.md.
  • Polish. Hit-stop, particles, a synthesized audio toggle, light and dark themes, pause, and a "Meet The Nerfs" roster page.

API

These are Vercel Node functions with default-export handlers. The ones that write data reject cross-site requests (403).

Endpoint Method Purpose
/api/player GET, POST Read or register the cookie-bound player and callsign (409 if the callsign is locked)
/api/submit-score POST Submit a run's score (401 if unregistered, 429 if rate-limited)
/api/leaderboard GET Top scores (the client asks for ?limit=25)
/api/telemetry POST Session start, end and presence heartbeats
/api/stats GET Aggregate, public-safe metrics

If the Redis env vars are missing, every endpoint returns 500 … not configured.

Run it

There is no package.json and no build step.

Game only. Any static server works:

python3 -m http.server 8000
# open http://localhost:8000

The canvas, assets and modules load this way. But the callsign, leaderboard and telemetry calls to /api/* will fail, because the functions aren't running.

With the API, deploy to Vercel (or run vercel dev) and set:

Variable Purpose
UPSTASH_REDIS_REST_URL Upstash Redis REST endpoint
UPSTASH_REDIS_REST_TOKEN Upstash Redis REST token

Note

vercel dev has not been tested against this repo. The functions use fetch against the Upstash REST API and have no npm dependencies.

Project layout

index.html          entry point: all screens + module scripts
js/
  main.js           game state, loop, canvas, input, viewport
  config.js         tunables, ranks, rug types
  player.js teams.js rugs.js pumps.js combat-ai.js burst.js pause.js particles.js
  ui.js             screens, HUD, results, share/score card
  leaderboard.js    callsign registration, score submit + retry, board
  telemetry.js      session + presence client
  audio.js nerfs-page.js
css/                style.css, polish.css, burst.css, identity.css
api/                Vercel serverless functions (Upstash Redis)
assets/nerfs/       roster portraits
docs/               ANALYTICS.md, CADE_OPS_STATE.md (project notes)

The game started out as "Cade Rush". The Redis keys still use the caderush: prefix, and localStorage uses cadenerf.v1.

Status

docs/CADE_OPS_STATE.md holds the most recent project notes (20 Aug 2026). They list two checks that were still open: a production deploy of the leaderboard repair, and a real-device submission of a score above 200,000. A "V2 Hunt" prototype was built and then reverted on main.

License

MIT. See LICENSE.

About

CADE OPS: a 60-second browser arcade game with a global leaderboard, plain canvas JS plus Vercel functions and Upstash Redis.

Topics

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages