AI can make video games, we all know that. Whether we see Levelsio's flight simulator or yet another try to push the boundaries by big companies like Google1.
A recent tweet by Adrian Chmielarz shows that it's very impressive.
Kind of reminds me of the times when Anthem showcases showed a beautiful game. Not the one we got, though. So much power, so many possibilities… for corporations to do what they're best at.
But enough about them. Let's talk about us, indies, so indie we can't finish a game ;-) Or start. Or both. Just me? OK.
I recently announced that I'm going all in on AI.
I decided to start with an experiment. But first, let me share some backstory with you.
The first thing I did after my announcement was to... check again MonoGame. I learned that since Unity's attempt to promote other game engines (and seeing how Godot benefited since then), the MonoGame Team has made some progress in making their documentation better. As every pro crastinator I just love tutorials, because what is better than more research and less doing? 😉
But thankfully, I encountered a compilation problem and thought to myself...
I'm doing it wrong. I shouldn't read tutorials, I should focus on letting the AI make the games for me!
I decided to check this in a simple experiment!
So far, the only game I managed to make is Pong in Raylib using a C# binding.
That’s why I decided to do the same using AI (Cursor mostly using Claude 3.5 Sonnet), but in three different frameworks:
Raylib and C
Rust and macroquad
C# and MonoGame
Speed of execution is not what I want to measure! Obviously, it's gonna be fast. What I wanted to check is...
How many errors will it generate
How much of an effort will the games’ infrastructure
How much of an effort will it be to launch it
Here's my prompt:
Using $_LANGUAGE_$ language and $_FRAMEWORK_$ library, implement a simple game of Pong. Use only simple shapes and no sound.
Just like that. Of course, those two variables were replaced.
And after the first time using it with Raylib and C, I managed to see something awesome.
And while my inner nerd wants to go on about the benefits of doing games this way, my inner developer had different thoughts:
Anyway… Here's what I learned.
C requires some configuration to run on Windows 😁 Did you know that the easiest way to get a command line compiler for C is to... install Windows Subsystem for Linux 😁 I mean… SRSLY WTF?
That and the make file, which is not a problem by itself, but the number of things you need to install to run a Raylib game can be staggering. The good thing is that AI notes all these instructions for me.
Had some problems to solve when I wanted to compile and launch. But no problem is a problem if you talk it through with the AI 😉 It's like marriage. You gotta talk with each other. Only here you have to pay for every dialogue 😁
And the AI has implemented gameplay for two players on one keyboard! And scoring, and that bar on the center of the screen.
The only problem is that it requires additional configuration outside of WSL.
Here's the result:
Rust is even easier. Doesn't need WSL, dependencies are written down in a file, and every dependency of the dependency is downloaded on build.
Although he only implemented playing for one player. Also, I would refactor struct names to be more concise.
Here's the result:
As for Monogame... It’s funny that when given an empty folder, Cursor will generate the code first and the csproj and other project-related files only once he can’t build the project. Running it, I encountered a record amount of errors that Cursor solved (by himself, but still).
Fun fact, although two players can play, there’s no scoring, and no division line.
The result:
If you want, you can check the code here (no human work):
https://github.com/klimcio/AI_made_Pong_experiment
On uploading the code to GitHub, I noticed this:
Consider that as trivia.
What's next?
My main problem is that I feel like a retard who has been granted Flash's possibilities. I can move as fast as possible. But my brain can't think that fast.
I can start making my first game. Because: WHY NOT?
I've noted ideas for a year now, but my system of prioritizing them is flawed. I need to make it better to make them and learn more. Because AI can write the game for me. But I still need to design it. Use knowledge I don't have, yet, because I was learning how to code games, not necessarily design them.
I guess I should focus on prioritizing my database, and start from the easiest 😁
And use more AI to make stuff.
Btw…
Although we all know that they're not serious about making a game, they're just making a statement, like they did with Stadia 😉
This is a nice and objective look at using AI in development. Thanks!