
Quantum Pass
Quantum Siege
A survival game about the day quantum computers break classical shields. Seal your score on QoreChain with a hybrid-sign
About
Quantum Siege is a small survival game about the day quantum computers break today's cryptography. You fly a ship that shoots the nearest enemy on its own, collect gems, level up, and release a Power Blast shockwave when your kills have charged it. At 1:30, Q-Day arrives: every classical shield breaks for good and a ring of quantum enemies closes in. Only the post-quantum Lattice Shield still holds. The game works with no wallet. After a run you can optionally connect QoreX and upload your score to the Diana testnet as one hybrid-signed transaction. The game reads it back from the chain and only calls the score "sealed" when the chain returns code 0, the exact record, the PQCHybridSignature extension and a pqc_hybrid_verify event with status verified. The Daily and Overall leaderboards are built only from those on-chain records.
How it's made
Plan. A small action game where the Q-day idea is in the rules (classical shields stop working on a date), plus an optional way to put a score on QoreChain. The approach: build the game as a pure, testable core first, then put the chain on top so the game never depends on it. Architecture. A create-qorechain-dapp fullstack-web scaffold (React 18, Vite, TypeScript) in four layers. - src/siege: the whole game as plain TypeScript. Fixed time step, seeded random generator, no DOM, no wallet, no clock, so the same seed and inputs give the same run. A test fails if this code ever imports the renderer, React or the wallet. - src/render and src/ui: canvas drawing and React screens. They read the simulation and never change it. - src/chain: the only code that touches QoreX or the SDK. - src/records: personal best, kept in localStorage. QoreChain features used (Diana testnet, qorechain-diana). - QoreX wallet through @qorechain/qorex-types (getQorexNative, hasCapability) and signAndBroadcast, with the run record in the memo (about 50 bytes, limit 256). - @qorechain/sdk: msg.bank.send and qorechainRegistry().encodeAsAny build a 1 uqor transfer to a score-registry address. HYBRID_SIG_TYPE_URL recognises the hybrid signature. - Hybrid signatures: a score is "sealed" only after the game reads the transaction back over REST and finds code 0, the exact memo, the right sender and recipient, the PQCHybridSignature extension and a pqc_hybrid_verify event with status verified. It also reads the account's post-quantum key record (/qorechain/pqc/v1/account/<address>) as extra evidence. - The Daily and Overall leaderboards query transfers to the registry address and keep only records that pass the same checks. What was hard. - Making "sealed" mean something. A wallet success message is not proof, so the label is computed from the chain's response, and every weaker outcome has its own name (recorded, sent but not confirmed, named failures). The hybrid extension can sit in two places in the transaction body, so the check reads both. - First send. QoreX registers an account's post-quantum key on its first send (one-time fee of about 0.09 QOR). The game checks for the key before sending and turns the "no PQC key" error into plain instructions. - The public REST API sends no CORS headers, so the browser cannot call it directly. A same-origin /lcd proxy (Vite dev server and a Vercel rewrite) fixes that. - Balance without breaking determinism. The Power Blast lives inside the simulation. With a meter cost of 25 a test bot blasted about 90 times a run and some runs passed ten minutes. Sweeping 30 seeds led to a cost of 60, about 6 blasts in an average two-minute run. - Load time. The SDK is about 3 MB, so it loads only when a score is uploaded. The game itself starts from a 200 KB bundle (68 KB gzipped). Limits. A score is a claim signed by the player: the chain proves who sent it and that the hybrid signature verified, not that the run was fair. The leaderboard reads the latest 500 transfers to the registry.
Timeline
Newly verified on chain: Hybrid ML-DSA-87 transactions, PQC key registration with proof of possession
New project.
Comments and questions
- No comments yet.