Why 2 hours
Most game projects do not die from being too hard. They die from being too big. You open the project on a Saturday, realize there are 40 hours of work left, close the laptop, and never come back. (We wrote about the patterns that kill solo projects: Why solo game devs never finish.)
A 2-hour scope kills that failure mode. You sit down once, you finish, you have a shipped game URL by dinner. Finishing one tiny thing resets the "I never ship anything" feeling more than any 12-hour guide can. After this, the bigger walkthroughs feel possible.
What you will build
Breakout. The 1976 Atari classic. By the end you have:
- A paddle that moves with the arrow keys and the mouse
- A ball that bounces off walls, the paddle, and bricks
- Angle control: where the ball hits the paddle changes where it goes
- A grid of 40 destructible bricks in 5 colors
- A score, 3 lives, and win and lose screens with restart
- The game exported to the web and uploaded to itch.io
What you need before you start
- Godot 4 installed (free, open source, ~50 MB, godotengine.org)
- A free Claude account
- A free itch.io account
- Roughly 2 hours, one sitting
New to Godot entirely? The Godot engine page has a 10-minute orientation. You do not need to finish it first, but it helps to know what the editor panels are called.
How to use this guide
Four 30-minute steps. Each step has one Claude prompt to copy, instructions for what to do in Godot, and a check. Do not skip ahead. If your game does not match the check, paste the error into Claude before moving on.
Project, walls, and the paddle
Open Godot, create a new project (call it "Breakout"), and choose the "Compatibility" renderer (it exports to the web cleanly). When the editor opens, start a new chat in Claude and paste this:
$ I am building a Breakout clone in Godot 4.x with GDScript. Fresh empty project. Give me step 1: the main scene, walls, and a player paddle. - A Main scene, root node Node2D, for a 640 x 480 game - Set the project window size to 640x480 - Three static wall colliders (StaticBody2D): left edge, right edge, top edge - A Paddle near the bottom. Use the node type you think is right and tell me why. - The paddle moves left and right with arrow keys, and also follows the mouse X - The paddle is clamped so it cannot leave the play area - Use plain ColorRect shapes for visuals, no image assets // constraints - Godot 4.x GDScript, no plugins or addons - Tell me every node to create, its type, and its name, as a tree - One commented script for the paddle - Explain anything non-obvious in one line, no essays
Follow Claude's node-tree instructions exactly. Create each node, attach the script. Press F5 to run.
Check: A 640x480 window. A paddle near the bottom. Arrow keys and mouse both move it. It stops at the walls.
ui_left and ui_right actions should already exist. If Claude used custom action names, add them there.The ball and the bounce
The ball is the heart of Breakout. The trick that makes it feel good: the bounce angle depends on where the ball hits the paddle. Same chat in Claude, paste:
$ Step 2: add the ball to the Breakout game from step 1. - The ball is a CharacterBody2D that moves with move_and_collide - It starts on the paddle and launches upward when I press Space - It bounces off the three walls and off the paddle - Paddle bounce uses angle control: if the ball hits the left part of the paddle it deflects left, the right part deflects right, the centre goes near-straight up. This is the classic Breakout feel. - The ball keeps a constant speed after bouncing (normalize, then re-scale) - The ball must resolve every collision in a frame, not just the first one. Loop move_and_collide until all motion for the frame is used up, so a fast ball never tunnels between two objects. We will add many bricks in step 3. - If the ball falls below the bottom edge, print "ball lost" for now // constraints - Keep the step 1 paddle code working - Godot 4.x GDScript - Ball speed and launch speed as @export variables so I can tune them - Return the full ball script and which nodes to add to the scene tree
Add the ball nodes, attach the script, run with F5. Press Space to launch.
Check: The ball launches up, bounces off the top and side walls, and bounces off the paddle. Hitting the ball with the edge of the paddle sends it off at an angle. Letting it fall prints "ball lost" in the Output panel.
A wall of bricks
Now the bricks. They are spawned from code, not placed by hand, so the layout is easy to change. Same chat:
$ Step 3: add destructible bricks. - Make a reusable Brick scene (Brick.tscn): a ColorRect plus a collider - A Bricks node in Main that spawns a grid: 8 columns x 5 rows near the top - Each of the 5 rows is a different colour - Spawn the whole grid from code in _ready(), evenly spaced with a small gap - When the ball hits a brick: destroy the brick and bounce the ball off it - The ball must bounce on the correct axis (hit from below = bounce down, hit from the side = bounce sideways) // constraints - Godot 4.x GDScript - Keep the paddle and ball from steps 1 and 2 working - The grid columns, rows, and colours should be easy to change at the top of the script - Return the Brick scene setup and the spawn code
Build the Brick scene, add the spawn code, run.
Check: 40 bricks in 5 colored rows. The ball destroys a brick on contact and bounces away. Clear a few rows to be sure the bounce direction feels right.
Score, lives, win and lose, then ship
Last step. Turn it into a real game with a goal and a fail state, then put it on the internet. Same chat:
$ Step 4: make it a complete game. - Add a score: +10 per brick destroyed, shown top-left with a Label - Add 3 lives, shown top-right. Losing the ball costs one life and resets the ball onto the paddle, waiting for Space again. - When every brick is destroyed: show a large "YOU WIN" message - When lives reach 0: show a large "GAME OVER" message - On either end screen, pressing Space restarts the whole game fresh // constraints - Godot 4.x GDScript - Put all UI on a CanvasLayer so it does not move with the game - Keep every behavior from steps 1 to 3 working - Return the full updated scripts and any new nodes
Wire it up, run, and play a full game start to finish.
Check: Score climbs as you break bricks. Lives drop when you miss. Clearing the board shows YOU WIN. Running out of lives shows GAME OVER. Space restarts.
Export to the web and ship to itch.io
- In Godot: Project, then Export. If you see "no export templates," click "Manage Export Templates" and download them once (free, a one-time ~700 MB download).
- Add a Web export preset.
- Click "Export Project." Save into a fresh empty folder. Name the main file
index.html. - Godot writes several files (index.html, .wasm, .pck, and more). Select all of them and compress them into one
.zip. - On itch.io: "Upload new project," set Kind of project to HTML, upload the zip, tick "This file will be played in the browser."
- Set the embed size to
640x480. Save, then "View page."
Your Breakout clone runs in the page. Share the URL.
index.html, or the zip has a folder inside it instead of the files at the top level. The files must sit at the root of the zip. Re-zip with everything selected directly, no enclosing folder.What to do next
- Add a power-up. A brick that drops a falling pickup; catching it widens the paddle for 10 seconds. One new scene, one timer.
- Speed ramp. Increase ball speed slightly every 10 bricks. One line in the brick-destroyed handler.
- Sound. A blip on bounce, a crunch on brick break. Godot's AudioStreamPlayer plus two short sounds.
- Multiple levels. Pair this with the level builder: design brick layouts as a top-down grid and load them as levels.
- Go bigger. Ready for a longer project? The weekend platformer walkthrough is the natural next rung.
Why this works
- The scope is locked. One paddle, one ball, one brick grid. No menus beyond win and lose, no levels, no save system. Two hours is exactly enough for exactly this.
- Breakout is a solved problem. Claude has seen a thousand brick-breakers. The prompts are specific enough that the code comes back clean and close to working.
- You ship at the end. The walkthrough is not done when the game runs on your machine. It is done when it has a public URL. That distinction is the whole point.
License and sharing
This walkthrough is CC0. The Claude prompts are CC0. The code Claude returns is yours. If you ship a game with this guide, a link to pixeldex.dev in your itch description helps the next person find it. Not required.