Live data from Hacker News

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

github.com

81–90 of 163 posts

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

#83
post #80

[flagged]

Please tell me - how exactly you think is typing English prose into a box different vs typing a bunch of english keywords and symbols in the exact correct order into a box? To me these are both conceptually the same. But typing English to me is an order of magnitude faster than typing code, especially in a domain that's new to me (like game dev).

> What did _you_ do? How were _you_ creative? Where in this project is _your_ passion?

My passion is, and was never in the act of typing code. It was put in creating something that's useful or, in this case - fun. It's the end product that matters to me. I've put a lot of thinking into how exactly each element should work, look and behave. Then I verbalized all this thinking and created prompts that got turned into code, which resulted in a game that's apparently fun for people to play. And that's it.

Thank you for taking time to check my project.

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

#84
post #80

[flagged]

Did you even look at the content of the post?

There's a prompts.md (link: https://github.com/maciej-trebacz/tower-of-time-game/blob/ma...) that shows what the author did in this project, most of which is providing creative direction and corrective nudges to the AI.

Most people only care about the end result, and vibe coding got the author there much faster and with less effort.

Your comment reads like a carriage driver bemoaning car drivers because they didn't have to feed, groom, harness, and command a team of horses, yet still arrived successfully at their destination.

"Why should I be impressed that you turned a wheel and pushed a pedal?"

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

#85
post #32

Earlier quoted context omitted.

I tried to build a simple static HTML game for the board game Just One, where you get a text box, type a word in, and it's shown full screen on the phone. There's a bug where, when you type, the text box jumps around, and none of the four LLMs I tried managed to fix it, no matter how much I prompted them. I don't know how you guys manage to one-shot entire games when I can't even stop a text box from jumping around t…

Same. I had some idea that I wanted to build a basic sinatra webapp with a couple features. First version was pretty good. Then I asked it to use tailwind for the css. Again pretty good. Then I said I wanted to use htmx to load content dynamically. Suddenly it decides every backend method needs to check if the call is from htmx and alter what it does based on that. No amount of prompting could get it to fix it.

Hard to tell what exactly went wrong in your case, but if I were to guess - were you trying to do all of this in a single LLM/agent conversation? If you'll look at my prompt history for the game from OP you'll see it was created with a dozens of separate conversations. This is crucial for non-trivial projects, otherwise the agent will run out of context and start to hallucinate.

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

#86

Earlier quoted context omitted.

I recently had a need to create educational animations. These were programmatically created using the Manim library in Python. I'm a mobile dev by trade. The best interaction i had recently was with Python and the Manim library specifically which are not my area of expertise. This was a series of "Create an animation that shows X with a graph of the result over variables Y". AI gave a one shot successful results with…

Would that have taken you weeks though? I imagine reading through a few articles and examples could have gotten you there. I never heard of Manim before but found these pretty quickly: https://docs.manim.community/en/stable/examples.html https://manimclass.com/plot-a-function-in-manim/ I am not trying to pick at you, but it feels like what I am currently able to do with AI, shave off a few hours, but not weeks. I agr…

A single graph might save hours. A full feature series where each graph type has yet new syntax to learn is indeed much more. Especially when there's followups, "let's make the graph move over the left half of the screen and then the next animation shows in the right half?" which again were one shot done in minutes with AI. For me just to gain the context of how to move the animation into the left half smoothly and then move all animations that were drawn into a separate animation file into this file and reposition each element from that second file into the right half of the screen would have probably taken a day.

We tend to underestimate engineering time generally. So i wouldn't look at the above and say "that seems doable in X hours". I stand strongly by my assertion that it saved me a week (at least!) all up.

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

#88
post #85

Earlier quoted context omitted.

Same. I had some idea that I wanted to build a basic sinatra webapp with a couple features. First version was pretty good. Then I asked it to use tailwind for the css. Again pretty good. Then I said I wanted to use htmx to load content dynamically. Suddenly it decides every backend method needs to check if the call is from htmx and alter what it does based on that. No amount of prompting could get it to fix it.

Hard to tell what exactly went wrong in your case, but if I were to guess - were you trying to do all of this in a single LLM/agent conversation? If you'll look at my prompt history for the game from OP you'll see it was created with a dozens of separate conversations. This is crucial for non-trivial projects, otherwise the agent will run out of context and start to hallucinate.

Agent mode in RubyMine which I think is using a recent version of sonnet. I tried starting a new agent conversation but it was still off quite a bit. For me my interest in finessing the LLM runs out pretty quickly, especially if I see it moving further and further from the mark. I guess I can see why some people prefer to interact with the LLM more than the code, but I’m the opposite. My goal is to build something. If I can do in 2 hours of prompting or 2 hours of doing it manually I’d rather just do it manually. It’s a bit like using a mirror to button your shirt. I’d prefer to just look down.

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

#89
Thanks for the read! I too have over 20 years in tech and have been going back and forth with Gemini-cli to gamify some tools for integration testing some Enterprise applications and it’s amazing what can be done with Gemini alongside usage of MCP servers. I am finding positive results if I approach problems in chunks and provide clarity in prompt instructions. The AI will make mistakes and sometimes get caught up in loops for some problems (like application routing.. lol) but I am happy to step in and effectively pair program with the AI when issues are present. I notice too that it has never been a better time to enforce things like how Duplication Is Evil because otherwise the AI may make a change in one area and forget that it has similar changes to make in another file. This applies both to programming logic as well as User eXperience and application behaviour.

Anyway what a world. It would have taken me weeks to create what an AI and myself are able to whip up in a few short, and fun, hours.

Giving a personality to Gemini is also a vital feature to me. I love the portability of the GEMINI.md file so I can bring that personality onto other devices and hand-tailor it to custom specifications.

Post reply on HN