Inspiration
A daily puzzle can give a community a small shared ritual: the same challenge, different approaches, and a reason to return tomorrow. Fix the Circuit turns that idea into a visible network: disconnected tiles become one working circuit.
What it does
Players rotate a scrambled 5 × 5 grid to spread power from a central battery. Green wires show live connections, while pink tips mark loose live ends. The goal is to power all 25 tiles without loose live wires. Each tap is a clockwise rotation; undo and reset make experimentation easy.
Everyone receives the same date-seeded puzzle. A new circuit arrives at midnight UTC. Progress is saved in the current browser when storage is available. After solving, players can copy a spoiler-free result to share manually. Authenticated Reddit completions contribute to the daily community count.
How it was built
The game runs inside Reddit using Devvit Web, with a lightweight inline launcher and an expanded React game. TypeScript shares the puzzle generator and replay logic between client and server. A seeded spanning-tree generator guarantees a connected reference solution, then scrambles tiles through rotation.
A Hono backend replays submitted moves before accepting a completion. Devvit Redis stores first completions and a set of unique daily players. Original SVG circuit tiles and CSS create the interface without external image assets or AI calls during gameplay. Development used OpenAI Codex for coding and debugging assistance, with explicit build checks, generator tests and a live Reddit playtest.
Challenges and what the project taught us
The main engineering challenges were generating reproducible, solvable daily boards; making disconnected live wires readable; and moving from a local web preview into Reddit's iframe and server environment. Sharing the replay engine across client and server kept the completion rules consistent. The deployment workflow also needed fixes for Windows shell quoting and the Node test TypeScript configuration.
Validation and accomplishments
Tests checked 365 daily seeds for deterministic generation, distinct scrambled boards and replayable solutions. Type checking, linting and the production build passed. A complete 42-rotation solve on Reddit was verified by the live server, incremented the unique-player count, and produced a working copied result.
What's next
Improve first-time onboarding, test more device and accessibility combinations, and explore personal streaks and richer community comparisons. Server replay is basic validation rather than comprehensive anti-cheat; public puzzle seeds can be solved programmatically. Streaks and competitive leaderboards are future work, not current features.
Built With
- devvit
- react
- redis
- typescript