Devlog 4: AI and Video Games
Gray is safe.
The thesis
I had to write a thesis on AI in video games, the history of artificial intelligence in video games. It certainly wasn't something the panel was used to, talking about AI, lightly talking about the technicalities and mostly talking about what it can do, what it could do for us. I haven't read the whole thesis in ages, and recently I thought I could compare my writing, my thoughts and ideas, test my beliefs. And while certainly I truly believe in some of the things I wrote, I have a different view on things now that AI has seemingly consumed the minds of many, be it positively, negatively, or subconsciously. Its impact has heavily affected multiple fields and careers, scarred so many people and left them stranded looking for alternatives. It didn't leave some markets unscathed either, notably computer memory. And who knows what the future holds.
What I believed in 2022
Back then, I believed in all sorts of things. So now I want to revisit some lines.
"We may create A.I. that can usurp us or almost entirely replace us, but if harnessed intelligently, A.I. can be used to craft deeper games, more meaningful storytelling experiences and can be used to examine ourselves."
Keyword being harnessed.
"it may only be a matter of time before A.I. itself is nominated for awards in game design."
Back then, as I wrote that, I was beaming. Genuinely. A machine showing an inkling of creativity. I thought that was the coolest thing.
Then the dream. I imagined Elizabeth from BioShock Infinite, but one that recognizes your text, your voice, the way you act, and a story that changes with you:
"what if A.I. was smart enough to craft not just dynamic gameplay scenarios for us, but also script an opera of adventure, hope and love..."
Now these might be the three points that changed for me. I truly believe in one still, one not so sure. And one I definitely don't. Though I will come back to this topic.
Then and now
I wrote the thesis at a very early stage of AI, people were raving about ChatGPT but I found it utterly stupid, it couldn't do much. I never relied on it for years. I was taught code by writing it on paper, that's how I started learning this whole venture. AI kept giving me so many wrong answers that it just proved worse at working on projects. So I avoided using it. And now comparing the present with that time. The difference in quality is orders of magnitude higher.
The vibe-coded graveyard
And this is where my first controversial take starts, I truly and wholly believe that code quality has gone up tremendously, but, and it's a big but, the way said code is put together, the architecture quality, has heavily declined, so many people just decide to create something, crunch for a day or two, publish, and then no longer know what to do. Many "vibe coders" just decide to write a project and then dump it for another.
If I could sum up my point. I would say that because the barrier to entry for writing individual lines of code has dropped to zero, the barrier to creating massive, structural messes has also dropped to zero. And so we are left with a vibe-coded graveyard of aborted ideas. When you build entirely by prompting, you skip the boring parts that make software resilient, be it writing a technical specification, mapping out data schemas, defining systems. And that's where you reach the wall, a vibe coded project feels like an insane achievement for the first 3 days. But software complexity scales exponentially, not linearly. By the 14th day when you are put in a situation where you need to change how user permissions propagate through five different microservices, the AI won't be helping you. This in turn makes it hard for you to untangle the system that was built because the AI took all the design and system decisions.
Don't get it twisted, code was never not spaghetti, anyone who has worked even on a semi large project will tell you code gets messy, no matter how you try, but I like to use the example of your mother's spaghetti, you know it well. You know how it tastes, or how she makes it.
I say this now. But I am the same person who, a couple of years ago, dismissed AI because I deemed it stupid. Yet here I am using it quite a lot. Does my reliance on it create an issue, maybe, maybe not. We can try to predict the future. But we can never be certain, hence why everyone plans. I know this part has dragged on, but I wanted to expand a bit on this topic, and what I, someone who was fortunate enough to learn before AI became used widely as a tool to finish your programming tasks, think about it.
Where I stand
I unfortunately see too many extremists when it comes to this matter. Either it is bad, or it's the greatest thing. I think that when harnessed correctly, it is an effective tool that boosts productivity. To get it out of the way. I am vehemently against using AI for anything creative, be it game art, writing, sounds, voices, game design, architecture, and anything that makes a human express themselves. To me, those should never be touched by AI. I can honestly tolerate the occasional, "what if I added this to my room, before doing it, I would like to know how it might look", and apologies to anyone who might disagree, but the majority of people won't be picking up the pen to draw, or start 3D modelling just to check if a couch they bought from some website would fit their corner. And neither will they hire someone for it. To me, as long as you aren't using it to profit from it, or to replace something that you could do. I can tolerate. But there is a topic I will discuss regarding this down this long wall of text.
But on the other side, when it comes to something that only requires churning, repeating, or just annoying tasks. I am all for it with rules that need following. Especially when it comes to coding, and as I mentioned a paragraph before, even then there are nuances.
Holding the reins
I dislike vibe coding, you can't just come over, use AI to create a broken website you can't even fix when it's broken. To me, an understanding of programming/writing code helps immensely to the effectiveness of using AI in code. You are aware of how you should structure your project, what libraries are needed, even the specifications in my honest opinion should be at least 80/90% your own thing. If you have a solid structure and specification, a document an AI can follow and you also follow, you will find much ease using AI. Now let's not deny AI going rogue sometimes, but it is very rare. As long as you hold the reins, you can genuinely progress.
Research
Which brings me to another point. Research. Truth be told when making my own volumetric cloud system. I didn't know where to start, didn't even know HLSL. But I refused to just prompt an AI to make it for me. I don't care how impressively complex your description of what you want is. If you don't know, or can't predict what it will write. It is all useless. So I did some research. A lot of it. From studying my own regional clouds where I lived, to studying rare clouds like lenticular ones, or horseshoe, amongst other cloud types, I didn't study just the shape, I had to know how they formed, all the circumstances around it, and why so. How light passes through the clouds and scatters, silver linings of clouds, cloud densities, coverage maps, and many more subjects. These all helped me, piece by piece determine the nature of what I want. From there I had to at least understand some HLSL, from raymarching techniques, to temporal reprojection techniques for optimizations. And from there I worked on specification documents, I went through 3 versions before finally settling on one thing.
I won't sit here and tell you that if you lock me in a room, tell me to write some form of raymarching code to create a basic shaped cloud and if I don't, my loved ones will die. They will die as I will not be able to. But I am aware that in raymarching, for each pixel, we take small steps and add up how thick the cloud would be there/along the way. I am also aware that Beer's law states the thicker the point is from the sun, the darker it is. The powder effect and silver linings. A lot of this knowledge comes from reading lots of documentation, and presentations made by developers that can save their loved ones.
Looking beyond what you see
Anything I work on in these times requires research. It's the one rule I never break unless I am writing a one file python tool. Clouds, the terrain, how a river carves its valley. You look past the surface and you ask how it is formed, and why it looks like that. So naturally I did the same with AI. Not recently of course, but it was maybe a year or two after my thesis that I decided to look some more into it. I already had a rough idea on how it works, that's not what interested me, but rather how it was made? and where did it learn from? And piece by piece, paper after paper, my mind switched up on some of the words and arguments I laid out in the thesis. Before I delve more. Understand that many people live in a bubble, or a small community, the majority of people aren't aware of AI and how it learns. You, the reader, might know, but remember, just because you know doesn't make it "obvious" so cut some slack to people unaware of its origins.
Now, models depending on what they achieve, learn from songs, drawings, animations, videos, books, writings, online. Years, lifetimes of people's work, taken off the internet, or scanned, pirated, without asking anyone. And you can't say no, which is what hurts most. If it is done. It's done. A company adding an "AI training on your art" consent button but opting you in, meaning anything you had posted then was already trained on because by default you were consenting, until you don't. And that same AI tool then becomes a product being sold to the masses. In an attempt to flush the ones it learned from and replace them. Now that quote about AI being nominated for awards in game design. That one, I changed my mind on. AI has gotten way too good. But learning the cost, the damage it caused and is still causing. I am taking back what I said.
This is the topic I promised further up. The couch in your corner, I can tolerate, nobody's living depends on it. But profiting off something built from artists who were never asked, that's where I draw the line. Or at least that's where I try to.
The code I learned from
Because here's the thing. I'm not clean either. I never truly wrote 100% original code. Not many do nowadays. Most of what I know, I learned by reading open source repositories. Or repositories/code people put online for free. Learned how to structure, picked up on naming schemes/patterns based on use case and language, their little habits, until they became mine. If you dig through my handwritten code, you'll find pieces of strangers everywhere. Not necessarily word for word but a pattern is there. And guess what these models learned code from. The same repositories. Some of them put licences on their work asking for credit, and the models never gave any. So why is it fine when I do it, and stealing when a machine does it? I could tell you it's about scale, the amount of repos I read in comparison to what models read is incomparable, they probably read everything that is public online regardless of licensing, so much so that I genuinely received code from ChatGPT, back then, that looked exactly like the code from stack overflow that helped me when I was in need, way before ChatGPT's name was ever written once on the internet, so it's not even the web search feature all AI come equipped with. I could also tell you it's about profit, those people shared their code so others could learn from it, nobody shared their drawings so a company could sell a machine that draws like them. Most importantly, I could tell you that code is a function and a drawing is an expression. All of those are true, a little. I am not convinced by all as I know some who treat code as passion and some who treat it as just a job, they don't care about new technologies. Same way for art. Some might genuinely just want to express their feelings and passion, others just want to sell something cool to look at. I think we have to be honest that if ever a balance was there, more artists treat their work as passion and expression than coders treat their code. So I'll just admit it. I hold code to a looser standard than art, and I am fully aware of it. Maybe that makes me a hypocrite. Or maybe it just makes me someone who hasn't figured it all out yet. Either way, I'd rather say it myself than pretend the line I drew is perfectly straight.
A dream, revisited
This part is where things, for me, get brutally gray.
Take Elizabeth. Say every line she speaks was written and voiced by a person. And every animation captured from an actor. All the expressions drawn by an artist. The AI doesn't make anything, it just decides when to use what. When to look sad, when to laugh, when to say the line.
Is that wrong?
Before you answer, Left 4 Dead's AI Director did almost exactly the same back in 2008. Everything was human made, but there sat a director that decided the beat of the game based on what it measured from the session's player level and skill.
But emotions are human. It's how we talk to each other, sometimes it's the only way some of us can. So when a machine picks the moment to show sadness, even with a human's face and a human's voice, whose sadness is it? The actor's? The designer's? Nobody's? Does it mimicking us strip something from us, even if every piece of it is ours?
And then of course, there's the design side. A perfectly told story, where every beat falls exactly where the writer wanted it. Or a story you put yourself into, it could be messy and different every time. If the designer wanted a specific path, he could have taken it. Handing control to the system was his decision. Is that still his story? Does it make less sense? Or is it just a different kind of art, the same way nobody asks if a film is more "real" than a tabletop game?
I don't have an answer. I'm not sure there is one. It is something that every individual would answer differently.
Path dependency
In my thesis, I also quoted Julian Togelius, who spent years trying to get game designers to use new AI methods:
"At conferences, I would try to convince game designers that their company stood to gain from using new ai methods, with the response being that it was unnecessary."
His point was path dependence,
"where past events have fixed us on a path to a specific future."
Games were designed around dumb AI, because AI was dumb when those designs were made. Every choice thins out the options, until you're locked on one road.
Funny how that changed. In 2022 the problem was games refusing AI. And now today everyone is running towards it. Studios, investors, even the memory market. The options are thinning again, just towards AI this time. And you can tell many games, especially from big triple-A studios are just repetition with a different skin.
And remember the graveyard from earlier? The barrier to entry dropping to zero? It doesn't stop at code. Open the app store and scroll through the mobile games, same AI art, same AI voice reading the same AI script, uploaded by the dozen, each one a reskin of the last. Steam isn't safe either, it got so bad they had to add a disclosure to store pages so you know when AI was used to make the game. And a lot of what's behind that label is garbage, made in a weekend to make a quick buck. The barrier to making a game dropped. The bar for what gets published dropped right along with it.
I learned code on paper, before all of this mess, I caught the beginning of it yes, but I still had my fundamentals. That path is why I write specs, and why I hold the reins. Someone starting today walks a different path, because they already have such tools in their possession.
Which brings me to the last part.
People change
Reading my thesis again was weird. It's me obviously, but a lot has changed. But I was a younger guy looking at the same thing from a different angle. I wasn't aware of the cost, it was just pure excitement. And I don't think he was totally wrong, I just think he didn't know as much as he does now. Right now I just know more, and with knowing more I find myself not knowing much. Now some might treat anyone's change of mind as a "loss". They would treat it like you were caught, like a deer in the headlights. But I didn't change my mind because someone threw their opinion at me on the internet and how it is the correct one. I changed the same way a person learning does. The same way I learned how clouds form, and how terrain evolves over time. How the air temperature can affect the effectiveness of take off, how propeller aircraft tend to naturally sway one direction because of the engine's torque, research and more research. That's what made me change my mind. And not everything changed. I talked about how harnessing is important years ago, and again today, and I never made the connection until now, as I am writing this sentence. I still think AI can make games deeper. I just care more about what it's made of, and who it's made from. Is the me writing this better than the one who wrote the thesis? I don't know. Wiser maybe, more careful each step I take for sure. But not better, and not worse, just changed. And people tend to do that.
Not black and white
So, those three lines from 2022. Harnessed, I still stand by. Awards for AI in game design, I don't, not anymore, especially not like this. And the dream, Elizabeth, the opera of adventure, hope and love... I genuinely don't know. Maybe it can be made right one day. Maybe it can't. You never know, I was wrong once already. I started this wanting to tell you where I stand. I think I instead ended up showing you how very gray this topic is. I typically hold code to a looser standard than art. I used to praise the thing I now push back on. I use it every day, on the very project I'm writing this devlog about. If that sounds messy to you, it is. What I do know is where my line is for now. The creative part stays human. Where your line is, that's yours to draw. I'm not going to tell you what to believe in, and neither can I tell you to change. I just wanted you to see mine, and how I got there.
Fifth entry. Slight detour.