top of page

Game Dev Log #3: Problems making game - Attack of the Bacilli - AI makes mistakes

  • Writer: Ian Vicino
    Ian Vicino
  • Jun 9
  • 3 min read
ree

I intended to host my Python-created game, Attack of the Bacilli, online so anyone could play it straight on the browser, but encountered problems. The problems came down to the fact that my site cannot host Python-coded applications, only HTML/JavaScript-coded applications. Luckily, there is a way to translate my Python game to a web-compatible version, but it requires that I modify my code in specific ways and use something called Pygbag.


I tried to make the adjustments myself, but my game was made using three different Python files, and the adjustments, as far as I was able to see, seemed like they required the game to be made with one Python file. Additionally, they required specific elements that I did not know how to add to my code. I encountered an error while trying to create my web-compatible game, and instead of reading the error code, which I later found out explicitly led me to repair my code, I decided to take the easy route, or so I thought, and ask ChatGPT.


I thought that not only would ChatGPT be able to solve my error, but also get my code exactly as it needs to be to be able to be translated by Pygbag. This did not happen, instead, it led to multiple hours of back and forth, over two days, with ChatGPT and then Gemini when the free version of ChatGPT said I had used it too much. I ended up going back to the error code, which I should have done when I first encountered it, which led me straight to how to fix my code. That was when I decided I would document this failure.

I ended up solving my error, but couldn’t get it to play online for a reason that still eludes me. So, instead, I decided to get an executable version of my game to work, which had multiple struggles of its own and lead to a complete reworking of my code, but I got it to work primarily on my own with easy questions asked to ChatGPT, since I now knew that it could not be trusted with “complicated” troubleshooting questions. If you are trying to troubleshoot or create Python code using AI, be warned that the AI will undoubtedly get something, if not most of it, wrong. It is pretty good at HTML code, however.


I should also mention the difficulties I faced with Gemini as well. Gemini, Google’s AI agent, is completely free to use, but has its limitations, which I discovered during this adventure, too. The prompts you give Gemini are limited, which means that I could not submit my full code to Gemini to use to help me troubleshoot it. It cut out my code after I posted my question, so Gemini was only able to see the first 20 or so lines of code. (The code I used to make Attack of the Bacilli takes up over 400 lines.) That was annoying,  but it would be a fantastic way for Google to one-up ChatGPT, by allowing an unlimited, or reasonably big, prompts to be asked to its AI agent.


Regardless, I wanted to document my difficulties with AI, so you can learn that artificial intelligence is a far way from being as intelligent as humans. I was able to solve my error easily when I stopped being lazy and read the error code. Python is great at describing the code that is causing an error, so a developer can fix it. The fact that ChatGPT didn’t read the error code and tell me exactly what to fix baffles me. I don’t think programming jobs will disappear just yet; they may evolve, but they will be here for a bit longer. Also, I think we are a far way from creating true, generally intelligent machines, in contrast with what corporate CEOs proclaim. To get truly intelligent machines, I believe, we need to develop AI algorithms that resemble how our brain functions better than the artificial neural networks used today do, but that is a story for another blog post.

 

 
 
 

Comments


bottom of page