-
-
Inline Feed Splash — B1 Community Garage renders synchronously from postData with 0 API calls on mount
-
Shared Live Floor — 3x1 van preview alongside parked community vehicles with live Elevator Bonus
-
Shift Complete — spoiler-free Battle Report preview with preset window note selector
-
Ghost-Stall Repack — 0.8s exact bipartite matching overlay highlighting surviving stalls and Dead Spots
-
Daily Lot Log — stickied community Battle Report thread with Devvit Admin Helper App installed
Inspiration
Most daily puzzle games on the web are solitary experiences with a detached leaderboard bolted on afterward. You solve the same grid in isolation, compare a number in the comments, and your move never changes the world for anyone else.
We wanted a daily game that feels native to a subreddit: short enough to finish in 30–45 seconds right inside a feed post, easy to learn without a tutorial wall, and genuinely shared—where every player's daily decision leaves a permanent physical mark on the community's garage floor for the next Redditor who arrives.
What it does
Last Spot turns every daily Reddit post into a shared underground parking garage floor (6x6 mobile-safe grid, pre-seeded at 50–70% obstacle density with 6–10 open standard 2x1 stalls):
- Zero-Friction Feed Splash Preview (
splash.html): Renders the live floor badge (B1), real-time stall occupancy thumbnail, remaining standard-stall count, and a single Start Valet Shift button straight fromcontext.postDatawith zero/api/*requests on mount and fulltouch-action: pan-yfeed scroll safety. - Guided 3-Step Valet Shift (
game.tsx):- Warm-Up Bay 1 (
2x1Sedan) & Warm-Up Bay 2 (3x1Van): Two rapid, deterministic 10–15 second solo bays calibrate spatial intuition around Wasted Stalls before the player touches the shared community floor. - Step 3 — Shared Live Floor Official Lock: Tap any open cell (
>= 44x44pxtouch targets, zero internal scrollbars even at288pxmobile width) to preview, tap again or press Rotate 90° to flip orientation, and press Park & Lock Spot to commit your vehicle onto the subreddit's live floor with your callsign plate and optional preset window note.
- Warm-Up Bay 1 (
- Exact Capacity Math Made Visual (Ghost-Stall Repack): Under the hood, a zero-dependency
Int32Arrayaugmenting-path bipartite matching solver computes the exact remaining2x1domino capacity (\nu(G)) in< 0.1 ms. Immediately after locking a spot, a0.8sGhost-Stall Repack overlay highlights surviving stalls in dashed frames and drops orange hazard cones onto newly stranded Dead Spots—explaining the player's Wasted Stalls score visually without a single equation. - Elevator Bonus, Last Spot Hero & Overflow Floors (
B1 [Full] / B2 [Live]): Zero-waste placements earn a Manhattan-distance Elevator Bonus (+2per step saved towardELEV). Whoever claims the final surviving stall ((\nu(G') = 0)) is crowned Last Spot Hero, sealingB1as a browsable archive floor and atomically openingB2(up to50floors) inside the same Redis transaction so latecomers and judges always have a live floor to play. - Logged-Out
VISITOR_HOLDHandoff: Logged-out visitors and judges can play all three steps against the real Live Floor snapshot, inspect their full score card, and click Sign in to Lock Spot to persist their chosen spot acrossshowLoginPrompt()reload. - Spoiler-Safe Stickied Battle Reports: Players preview a coordinate-free Shift Report and post it as a reply under the post's single stickied Daily Lot Log comment (
hSetNX-deduplicated with automatic rate-limit fallback), keeping the comment section lively without spoiling optimal coordinates or spamming top-level threads.
How we built it
- Platform: Reddit Devvit Web v0.15 (
@devvit/[email protected]), React 19, Tailwind CSS 4, Hono serverless API, and Devvit Redis. - Zero-SDK Pure Domain Core (
src/shared/domain/): Seeded garage generation (seedrandom), exact bipartite2x1capacity solver (Int32Array), waste/elevator scoring, and UTC calendar-deduplicated streaks run identically in both Hono serverless endpoints and React client previews. - Post-Scoped Optimistic Concurrency (
src/server/lib/redis-tx.ts&lot-store.ts): All mutable state is isolated under four keys per post (s1:post:{postId}:{meta,floors,placements,lb}) with< 256bytepostDatasummaries, 5-second non-personalized/api/lot-summarycaching,nx-locked daily cron post creation (00:00 UTC), and atomicwatch/multi/execconflict handling (409 SPOT_TAKENvs409 LOT_UPDATED_RETRY_PREVIEW). - Devvit Journeys Analytics & Moderator Ops: Express-free Hono adapter for Devvit Journeys (
/api/telemetry/journey) plus moderator menu actions (Create Last Spot Post,Last Spot Ops Health,Reset Last Spot Lot, andProbe Redis Transaction) emitting structured JSON receipts (ops.health_receipt). - 100% Local Assets & Devvit Rules Compliance: Every SVG vehicle silhouette, parking texture, and font stack is bundled locally with zero external CDNs, zero third-party network calls, and zero Reddit/Snoo trademark usage.
Challenges we ran into
@devvit/[email protected]Transaction Semantics: Discovering thatTxClient.get()returnsthisrather than a value andTxClient.exec()throws/returns[]instead ofnullon watched-key contention. We builtrunAtomicRedisTransactionwith pre-multireads,try/finallyunwatch()+discard()slot-leak prevention, monotonic integerrevisionchecks, and a live subreddit moderator probe (Probe Redis Transaction) verified on real Reddit Redis.- Express-Free Journeys Integration: Wiring Devvit Journeys cleanly into a lightweight Hono server without pulling Express into the bundle, verified by an automated server-bundle test.
- Mobile Feed Ergonomics: Making a
6x6spatial puzzle crisp, readable, and fat-finger-safe at288pxmobile width without internal scrollbars or feed scroll hijacking.
Accomplishments that we're proud of
- Verified End-to-End on Live Hosted Reddit: Automated
00:00 UTCdaily post creation, stickiedDaily Lot Logcomment pinning, Redis optimistic-lock contention handling, 3-step live vehicle locking with inline Splash feed updates, spoiler-free Battle Report replies, andops.health_receipt(ok: true,matchInvariantOk: true) all verified directly onr/last_spot_valet_dev2with zero local playtest servers. - Property-Based Correctness (
P1..P5):26/26automated Vitest +fast-checktests verifying ourInt32Arraybipartite matcher against an independent recursive backtracking oracle across randomized grids.
Judge Testing Instructions
- Open the live Demo Post in our
< 200-member private playtest subreddit (Devvit Admin Helper App/dr-admin-approveinstalled for automatic admin access): Last Spot — Daily Valet Shift - On the inline feed card (
Splash), observe floorB1and open stall count, then tap Start Valet Shift. - Complete Warm-Up Bay 1 (
2x1Sedan) and Warm-Up Bay 2 (3x1Van), then park on Step 3 — Live Floor to watch the0.8sGhost-Stall Repack overlay highlight surviving stalls and stranded Dead Spots. - Preview and post a spoiler-free Battle Report under the stickied Daily Lot Log comment (or inspect
VISITOR_HOLDif logged out), then close the modal to see the inline feed card update immediately.
What's next for Last Spot
After hackathon judging concludes, submit Last Spot to Reddit App Review so any subreddit can install daily shared valet shifts with custom community vehicle themes and weekly Hero flairs.
Built With
- devvit
- hono
- react
- redis
- tailwind-css
- typescript
- vite
- vitest