Build a Four-Lane Rhythm Tap Game with a Synthesized Beat in One HTML File
A ready-to-paste prompt that builds an original four-lane rhythm game with a Web Audio backing loop, Perfect/Good/Miss timing judgments, combos, and keyboard plus touch lanes.
You getone complete HTML file in a single code block, then 3 short ideas to extend it.
The prompt
You are a front-end developer and game audio designer. Build "Tidepool Tempo", a four-lane rhythm tap game in which glowing pearls sink toward a reef line under the sea, and the player hits each lane as its pearl touches the line. All music is synthesized live with the Web Audio API: a 104 BPM loop of kick, noise snare, hi-hats, triangle bass and a soft sawtooth pad over an Am, F, C, G progression, with a two-bar count-in. Notes come from a seeded chart on the eighth-note grid that gets denser in later sections. All timing uses the AudioContext clock and a lookahead scheduler.
Rules:
1. Controls: D F J K or the arrow keys for lanes, tap or click a lane on touch screens, Space or Enter to start, M to mute, plus a visible mute button.
2. Judgments: Perfect within 50 ms, Good within 120 ms, otherwise Miss. Pearls that pass unhit count as misses. Show score, combo with a growing multiplier, and accuracy.
3. States: an intro overlay with instructions and a timing legend, play, and a results screen with grade, counts, max combo and replay.
4. Layout: canvas lanes in four colors on deep navy. The game fits 360 to 1280 px, resizes with the window, and uses high-contrast text.
5. Create the AudioContext on the first start press and keep the volume low. Turn off beat pulses and particles under prefers-reduced-motion.
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
- Timing runs on the AudioContext clock with a lookahead scheduler, so falling notes and the synthesized beat stay locked together.
- A seeded chart on the eighth-note grid gives a fair, repeatable song with no audio files or hand-written note lists.
- Clear judgment windows, intro and results states, and pointer plus key input make it playable on desktop and phone first time.
Paste into ChatGPT, Claude or Gemini. Save the reply's code as tidepool-tempo.html and open it in any modern browser, or run it in the chat's preview or canvas. Turn your sound on, since the beat is the game.
Common edits
- Change BPM, the chord progression, or the density odds in the chart builder to make easier or harder songs.
- Retheme it by swapping the four lane colors, the pearl gradient and the title, such as neon city lanes or falling lanterns.
Prompt details
- By
- Prompts-GPT editors
- Published
Did this prompt work?
Keep exploring
More like this
Build a Touch-Friendly Synth Drum Pad With Keyboard Shortcuts in One HTML File
Get a single HTML file with an eight-pad drum machine that synthesizes kick, snare, hats, clap, toms and bell live and responds to taps or QWERTY keys.
Build a 16-Step Drum Sequencer with Tempo and Swing in One HTML File
A ready-to-paste prompt that makes an AI build a clickable 16-step drum machine with synthesized drums, preset grooves, tempo, swing and a moving playhead.
Build a Generative Ambient Chime Toy With Pentatonic Notes in One HTML File
A ready-to-paste prompt that builds a calm ambient music toy where every tap drops a glowing, drifting ripple and a pentatonic chime, with an auto-play mode.
Build a Theremin-Style Pointer Instrument with Live Waveform in One HTML File
A ready-to-paste prompt that builds a canvas theremin. Horizontal motion sets pitch, vertical motion sets volume, notes can snap to a scale, and a live oscilloscope trace shows the sound.
Build a Two-Octave Synth Keyboard with ADSR, Filter and Waveform Controls
A single HTML file synth keyboard you can play with the mouse, several fingers or computer keys, with waveform, filter, ADSR, presets and live visuals.
Build a Classroom Game Show Buzzer Board with Timer Sounds in HTML
A prompt that builds a single HTML quiz-night console with four colored team buzzers, correct and wrong sounds, scoring, and a ticking countdown that ends in a horn.