I built a gravity powered space game with AI, and it turned out better than I expected

By (@thebuilderx) · · Games

I've always liked experimenting with AI beyond simple apps, so I gave myself a challenge: build a complete browser game in a single day. The idea became GRAVITON—a gravity based space game where you launch a probe across planets and use their gravity to reach a black hole. I had no real game development experience before this, so instead of spending weeks learning a game engine, I worked alongside AI as a pair programmer. I described the mechanics, tested every version, pointed out what felt wrong, and kept refining it until it felt enjoyable to play. The most interesting part wasn't generating code it was the iteration. We went through dozens of small improvements: fixing the physics, making planets look better, adding sound effects, redesigning the UI, introducing achievements and leaderboards, and improving the overall game feel.
This project reminded me that AI isn't replacing the creative part of building, it removes a lot of the friction between an idea and a working product. If you've ever had a project sitting in your notes because it felt too big to start, AI makes it much easier to turn that idea into something people can actually use. I'd love to hear what you'd add to the game or improve next

Tech stack

  • Claude
  • Claude Code

Prompt

"Build me a browser game where you slingshot a ball through space using 
planet gravity to reach a black hole — like golf but in space. 
Single HTML file, canvas-based, no libraries. 
Add a leaderboard, pilot profiles, achievements, and realistic planet visuals."

From there I iterated through about 30+ rounds of feedback:
- "the ball gets stuck to planets, fix it"
- "planets don't feel realistic, improve them"  
- "add sound effects for shooting and capturing"
- "improve the UI, it looks vibe-coded"
- "rename the game, don't use comet"

Each round the AI understood the context, made the change,
and kept everything consistent. The final game is ~2700 lines of code
that I could not have written this fast alone.

Comments (1)

  1. Jack Herzlich ·

    Cool to see you making games now. You should post this on the games section 👀 This is a lot of fun!

16 likes · 1 comment · 6 views

Explore more on Prompted