AWS Logo
Menu
How I Built Two Games in Under an Hour with Amazon Q CLI

How I Built Two Games in Under an Hour with Amazon Q CLI

Built Match-3 and 2048 using only Amazon Q CLI. A quick dive into how powerful, intuitive, and developer-friendly this tool really is.

Published May 26, 2025
This Sunday, I gave myself a fun little challenge: try something new, keep it light, and hopefully learn something along the way. I decided to explore Amazon Q CLI, Amazon’s new AI assistant for developers—and by the end of the afternoon, I had built two complete games with its help.
What started as a casual test of an AI tool quickly turned into a super productive (and surprisingly enjoyable) game dev session. If you’ve got even 30 minutes to spare, you can try this too.

Getting Set Up with Amazon Q CLI

Setup was refreshingly easy. I followed the getting started guide by Ricardo Sueiras, which walks you through everything—from installation to your first commands. It only took a few minutes, and I was ready to start building right from my terminal.

Game 1: Match-3 Puzzle

I began by asking Q to help me build a match-3 puzzle game—something similar to Candy Crush. The first prompt generated a grid and colorful gem sprites, but at that point, the gems weren’t interactive. In my second prompt, I asked for swap functionality, and Q delivered: gems could now be selected and swapped, and matches would disappear with scoring updates.
However, there were some bumps. If a swap didn’t result in a valid match, the game would crash and exit. It took a few more iterations to fix this—handling invalid swaps gracefully, preventing premature game exits, and resolving some pesky indentation errors that crept in along the way.
What impressed me, though, was Q’s responsiveness. Every time I spotted an issue or requested a design change—whether it was resizing the grid, adjusting gem colors, or changing the selection border—it implemented them efficiently. The final version felt like a genuinely playable game that I had co-created with AI.

Game 2: 2048

Next, I wanted to try something ambitious, so I simply asked Q to “create the 2048 game.” And what happened next was kind of incredible.
Within seconds, it generated over 600 lines of clean, structured code that ran without issues. It included the familiar 4x4 grid, tile merging logic, smooth animations, score tracking, game-over detection and win conditions at 2048. All I had to do was tweak the spacing between the title and score display to make it look a little nicer—but the game itself worked flawlessly right out of the gate.

Pygame

For both games, I used pygame—a simple, Python-based game development library that’s perfect for quick prototypes and beginner-friendly projects. It’s lightweight, easy to install, and has great documentation, making it a solid choice when working with AI-generated code.
That said, if you’re looking to explore more advanced options, you could try Godot (open-source and ideal for both 2D and 3D), Unity (great for more complex or commercial games), Phaser.js (perfect for browser-based games), or even Panda3D if you want to stick with Python but need more power.
The best part? Amazon Q is flexible. It can generate for whatever engine or language you're comfortable with.

Final Thoughts

What stood out was that this wasn’t just code generation—it was collaborative development. The code Amazon Q produced was well-structured, commented, and complete. It didn’t give me fragments or guesswork; it gave me working games that I could run, tweak, and extend.
Even when there were bugs or improvements to be made, Q handled feedback well and responded like a helpful teammate would. It felt less like a tool and more like pairing with someone who just happens to write code incredibly fast.
What started as a spontaneous side quest turned into a really satisfying way to spend a Sunday afternoon. I didn’t need any special setup or deep learning prep—just a bit of curiosity and a willingness to try something new.
If you’re a developer, student, or hobbyist, and you’ve been curious about how AI might actually help with your work—give Amazon Q CLI a shot. Whether you’re building games, tools, or just testing ideas, this is one AI assistant that can keep up.
Tried Amazon Q CLI already? Thinking about it? Would love to hear what you’ve built—or want to build—below.
 

Comments