Build a Five-Lock Digital Escape Room for Students
A digital escape room for students in one HTML page: five different puzzle locks, a countdown timer, tiered hints and a teacher answer key, ready for a laptop or projector.
Text prompt for ChatGPT and Claude
You get: one complete HTML file in a single code block, then 3 short ideas to extend it.
The prompt
Act as a front-end developer and classroom game designer. Build 'The Locked Observatory', a digital escape room for students aged 10-14. Start with a short story intro (the class is locked inside a scientist's hilltop observatory) and a Start button with a 10, 20 or 30 minute timer choice. Five locks appear as cards that open in order. Each uses a different mechanic with an original, factually correct science or logic puzzle: 1) a 3-digit code from three clues, set with +/- dial buttons; 2) a Caesar-shift cipher with a decoder wheel turned by buttons, answer typed; 3) an ordering lock for 5 steps using up/down buttons; 4) a matching lock pairing 4 terms with 4 definitions by clicking one then the other; 5) a final word whose letters come from the previous four answers.
Rules:
- Wrong answers shake the lock (skipped under prefers-reduced-motion) and show a short nudge. Right answers animate the padlock open.
- The countdown has a Pause button that hides the puzzle. Each lock offers 3 hints that get more direct, and each hint adds 1 minute to the final time.
- The finish screen shows escaped or out of time, total time, hints used and a Teacher answer key toggle.
- Every control works by keyboard with visible focus and clear labels. Never show status by colour alone.
- Use a calm light theme that respects prefers-color-scheme: dark, with system fonts. It must fit 360-1280px and read well on a projector. No forms, storage, alerts, external files or network requests.
Output format: one complete HTML file in a single code block, then 3 short ideas to extend it.Example output
Tips and common edits
Why this works
- Naming all five lock mechanics up front gives the model a clear build plan, so every puzzle arrives working and distinct.
- Requiring up/down and click-to-pair controls instead of drag-only keeps every lock keyboard- and touch-friendly on the first try.
- Tying the final word to earlier answers and asking for an answer key makes the puzzles self-checking for teachers.
Paste into Claude and open the result as an artifact: preview it there, then publish or share the artifact link with students. It also works in ChatGPT canvas or Gemini Canvas, or saved as an .html file and opened in any browser.
Common edits
- Rewrite the five puzzles for your own subject (fractions, a novel, a history unit) while keeping the dial, cipher, ordering, matching and final-word mechanics.
- Add team mode: a team name field on the start screen, a larger projector layout and the team name shown on the finish screen.
Reuse it: Use in a workflowTurn into a skillAdapt in the builder
Prompt details
- By
- Prompts-GPT editors
- Published
Did this prompt work?
More like this
Build a Word Scramble Puzzle Game with Hints, Categories and Streaks in HTML
A prompt that produces a single-file word scramble game with themed categories, paid letter hints, streak bonuses, and both typing and tile-tapping controls.
Build a Neon Circuit-Routing Tile Puzzle Game in One HTML File
Create VoltGrid, a self-contained neon circuit-routing puzzle game with guaranteed solvable levels, par tracking, and Web Audio lock-in clicks.
Build a Word-Chain Ladder Puzzle Game with Hints in One HTML File
Create RungCraft, an offline word-ladder puzzle game with a built-in dictionary graph, BFS shortest-path par, step-by-step hints, and move efficiency ratings.
Build a Color Sequence Memory Game with Synth Tones in One HTML File
A ready-to-paste prompt that builds Echo Garden, a four-pad color-and-shape sequence memory game with Web Audio tones, a strict mode and rising speed.
Build a Daily Five-Letter Word Guessing Game with Colorblind Mode in One HTML File
A ready-to-paste prompt that produces Quillmark, an original daily five-letter word game with correct duplicate-letter coloring, an on-screen keyboard and a colorblind mode.
Build a Four-Lane Rhythm Tap Game with a Generated Beat in One HTML File
A ready-to-paste prompt that builds a complete four-lane rhythm tap game with a live Web Audio beat, Perfect/Good/Miss timing grades, combo scoring and a results screen.
- Build a Gnome-Popping Whack-a-Mole Game With Decoys in One HTML File
- Build a One-Button Fox Endless Runner Game in a Single HTML File
- Build a Paddle and Bricks Game with Power-Ups and Levels in One HTML File
- Build a Procedurally Generated Maze Escape Game with Timer and Fog of War
- Build a Reaction Time Tester Game with False-Start Detection in One HTML File
- Build a Sliding Number Puzzle Game with Solvable Shuffles in One HTML File