I Built Tetris With AI — and Add a Dancing Dog
✨ Why This Matters
Building a game like Tetris used to take days of coding, debugging, and design work.
But with GenAI tools like ChatGPT and Windsurf, I was able to create a fully functional, animated Tetris game — complete with a dancing golden retriever 🐶 — using just natural language prompts.
This isn’t just about fun. It’s proof that Agentic AI is changing how we code, learn, and build.
🧰 Tools I Used
Tool | Purpose |
---|---|
ChatGPT | Generated the initial logic and description of the Tetris game |
Windsurf | Converted the prompt into working HTML/JavaScript game code |
Custom GIF | Used for a fun animation when lines are cleared in the game |
🕹️ What I Wanted to Create
I wanted to recreate the classic Tetris game with a GenAI twist:
- Built entirely using AI-generated code
- Resizable and centered UI
- Each time you clear lines, a different golden retriever celebrates with a new dance!
📝 My Prompting Workflow
-
Started in ChatGPT:
I asked it to describe how to build Tetris in detail. -
Pasted into Windsurf:
Windsurf turned the logic into a playable browser-based game. -
Refined the layout:
When the layout wasn’t right, I just asked:
“Can you center the game window and make it bigger?” -
Added the fun part:
I prompted it to add a dancing golden retriever gif when a line clears. -
Fixed the broken GIF:
The first embedded link didn’t work, so I replaced it with a working one and updated the code in Windsurf.
🎯 The Result
✅ A fully playable game
✅ Resized and visually centered layout
✅ A golden retriever that dances every time a line is cleared 🐾
🧭 How to Do This Yourself
- Go to ChatGPT – and prompt it to describe the logic of a game (like Tetris)
- Paste the output into Windsurf – and let it scaffold the game
- Use conversational prompts to:
- Resize layout
- Center the window
- Add animations
- Replace media or tweak the logic directly in the IDE
- Test and share!
💬 What’s Next
I’ll share the complete video walkthrough from start to finish.
📩 Subscribe to GenAI 4 Life for more creative GenAI experiments
🔗 Follow me on LinkedIn for behind-the-scenes builds and experiments