Live data from Hacker News

Show HN: I AI-coded a tower defense game and documented the whole process

github.com

1–10 of 163 posts

Show HN: I AI-coded a tower defense game and documented the whole process

#1
I'm a software developer with 20+ years of experience but during this time I never programmed any games, but I really wanted to for the longest time. With the advent of AI coding agents I thought that this is the best time to try and so I've learned a bit of Phaser.js (a Javascript based game engine) and entered Beginner's Jam Summer 2025 - a game jam for beginners in the game dev industry that allows AI coding. After around 25-30 hours (working mainly after my full-time day job) I managed to submit the game I called "Tower of Time" (the theme of the jam was "Time Travel").

You can play it in your browser here: https://m4v3k.itch.io/tower-of-time

The goal of this project for me was first and foremost to see if AI coding is good enough to help me with creating something that's actually fun to play and to my delight is turns out the answer is yes! I decided to document the whole process for myself and others to learn from my mistakes, so both the code AND all the prompts I used are published on GitHub (see submission link). The art assets are largely taken from itch.io artists who shared them for free, with some slight touch ups. Sounds came from freesound.org.

I've also streamed parts of the process, you can watch me working on the final stretch and submitting the finished game (warning, it's 5+ hours long):

https://www.twitch.tv/videos/2503428478

During this process I've learned a lot and I want to use this knowledge in my next project that will hopefully be more ambitious. If you have any comments or questions I'm here to answer!

Show HN: I AI-coded a tower defense game and documented the whole process
github.com

Re: Show HN: I AI-coded a tower defense game and documented the whole process

#2
This is a pretty cool game! I love the twists of rewinding time and playing with the keyboard. It would look pretty cool on Reddit, with a level builder. Redditors could build levels to challenge each other and see who can reach a highscore on each of the UGC levels. Check out Flappy Goose and Build It on Reddit to see some examples.

Re: Show HN: I AI-coded a tower defense game and documented the whole process

#5

How many tokens did you use up and what did you pay for them?

I can't give you the token count because I didn't really track that (Augment Code does not give you detailed token stats) and I'm not paying per token - I use the Developer plan on Augment Code ($50/mo) and Pro plan on Cursor ($20/mo). Didn't pay for additional usage and I have requests to spare on both of them.

As far as stats go from the provider dashboards I see:

- 7667 lines of Agent Edits accepted on Cursor

- 105 messages (prompts) on Augment Code

Re: Show HN: I AI-coded a tower defense game and documented the whole process

#6
This is awesome. I've been in software for 20+ years now as well.

One thing I've noticed is many (most?) people in our cohort are very skeptical of AI coding (or simply aren't paying attention).

I recently developed a large-ish app (~34k SLOC) primarily using AI. My impression is the leverage you get out of it is exponentially proportional to the quality of your instructions, the structure of your interactions, and the amount of attention you pay to the outputs (e.g. for course-correction).

"Just like every other tool!"

The difference is the specific leverage is 10x any other "10x" tool I've encountered so far. So, just like every tool, only more so.

I think what most skeptics miss is that we shouldn't treat these as external things. If you attempt to wholly delegate some task with a poorly-specified description of the intended outcome, you're gonna have a bad time. There may be a day when these things can read our minds, but it's not today. What it CAN do is help you clarify your thinking, teach you new things, and blast through some of the drudgery. To get max leverage, we need to integrate them into our own cognitive loops.

Re: Show HN: I AI-coded a tower defense game and documented the whole process

#7

This is a pretty cool game! I love the twists of rewinding time and playing with the keyboard. It would look pretty cool on Reddit, with a level builder. Redditors could build levels to challenge each other and see who can reach a highscore on each of the UGC levels. Check out Flappy Goose and Build It on Reddit to see some examples.

Thanks! The game actually supports gamepads too but I didn't have enough time to put in proper instructions for that.

Re: Show HN: I AI-coded a tower defense game and documented the whole process

#8
post #6

This is awesome. I've been in software for 20+ years now as well. One thing I've noticed is many (most?) people in our cohort are very skeptical of AI coding (or simply aren't paying attention). I recently developed a large-ish app (~34k SLOC) primarily using AI. My impression is the leverage you get out of it is exponentially proportional to the quality of your instructions, the structure of your interactions, and t…

> the leverage you get out of it is exponentially proportional to the quality of your instructions, the structure of your interactions, and the amount of attention you pay to the outputs

Couldn't say it better myself. I think many people get discouraged when they don't get good results without realizing that for good results you need to learn how to interact with these AI agents, it's a skill that you can improve by using them a lot. Also some AI tools are just better than others for certain use cases, you need to find one that works best with what you're doing.

When it finally clicks for you and you realize how much value you can extract from these tools there's literally no coming back.

Post reply on HN