A Future of Polygonal Friends: AI & Emotional Attachment (Part 2)

This piece is split into three parts (Part 1 is here, Final Comments are here), and was written for the Critical Distance Blogs of the Round Table. 
In the previous part, we covered the following:
  • Great video game stories need a varied cast.
    • But games often have identikit characters that only feel superficially unique.
  • To give characters depth, they need unique and varied dialogue.
    • But dialogue reacting to context is very uncommon.
    • Characters that say little or repeat often are very jarring.
    • Dialogue trees are a possible solution, but have limitations.
Those issues can be solved with some experienced and skilful writing, but there’s a way to both alleviate those flaws, and progress in interesting directions – the inclusion of AI.

What does AI entail? 

Artificial Intelligence is essentially a system of search engines. Put that way it’s not particularly glamorous, but that’s the truth. Artificial Intelligence has been around since the 1950s, and has been the target of obsession by both engineers and science fiction writers of varying quality.


While a lot of our modern technology already has a measure of AI to make our lives easier (even the Auto-Correct on your phone is an AI), we romanticise the idea of social, humanised machines that can be our best friend – or cruellest enemy. And autonomously at that. This is definitely relevant for video games – any character action that’s designed to happen in a way out of the player’s control – however slight – is the result of AI programming.

Narrative writing and AI are not necessarily mutually exclusive. It’s a reasonable point of contention – “How can something not controlled by the player be part of the story?” Most games keep story and gameplay as separate concepts – since if the story is places out of the players hands, there’s the chance that they could actually miss out on the story – a scary thought. However, with a little experimentation, and some advances in how we can program and utilise AI, we can blur the line into something unique.

What makes ‘em tick: AI and interaction

NPCs don’t mean a whole lot if the player can’t interact with them. In the vast majority of games, this details ways to fight or kill them. Not a whole lot of design is required to make a to-be-killed NPC ‘convincing’, as long as their demise is satisfying enough – but for NPCs that exist outside of a need to be mowed-down, the bar is suddenly set a lot higher for responses to player input. Hell, even major names in the games design industry are starting to recognise how important, yet how undervalued NPC AI is.


This is largely down to empathic reasons. We as humans intrinsically know how rational people react to certain situations. If we help someone they’re grateful, if we tell a funny joke they laugh, etc. So, when a character – especially an NPC in a game with a narrative focus – behaves in a way that isn’t rational human behaviour, it’s jarring. When used intentionally it can create an effective unsettling mood; but often occurrences are unintentional, and it breaks whatever ‘immersion’ the player might be having with the setting.

The problems I’ve brought up in the previous part are closely related to this jarring feeling. Homogeneous characters don’t feel convincing when we know how people can vary so much in real life. Characters with unchanging disposition feel like the Terminator (with maybe fewer homicidal tendencies), and ones with unchanging dialogue are just that much more two-dimensional.

AI can definitely be handled badly. 2005’s Façade was a breakthrough in AI and interactive drama, but its open-endedness was its downfall (to ignore the bare bones graphical presentation). Harassing the confused AI became something of a Youtube fad.


AI and Character Design 

Building on the concepts brought up before, this matters to character design diversity since people with different backgrounds are obviously going to think differently. It’s one thing to have a game character act uniquely within the plot, but when it comes to general gameplay, they often behave just like any other ally or enemy. It’s common in RPGs where you can give instructions to AI allies that different allies will act in the same way if given the same instruction (discounting things like different equipment load outs).


The Sims is the all-encompassing example about AI’s effect on character design. Any given character in the game is a bundle of personality traits and quirks, which manifest themselves in any action a Sim will take, even in subtle ways. The Sims 3 raises the curtain a little on how this process works – the player can select five specific personality traits when making a Sim, so the effects of these choices are more obvious. And with the 63 different Traits to choose from (and that’s not including the expansions!), you’ll be hard pressed to get two Sims alike by chance.

Charismatic, Dislikes Children, Neurotic, Perceptive, Schmoozer. Me in a nutshell, really.


Applying this to characters out of the player’s hands is definitely an interesting direction to go down. Party members that are different in every way, right down to how they deal with a problem would make them so much more distinct. If these personalities were randomised from game-to-game, no two players would have the same experience.

AI and Character Dialogue 

AI matters to dialogue variety because no one maintains a single way of speaking. We change how we talk depending on who we talk to, or just how we’re feeling at the time. It’s jarring in a game to do something that upsets a character, only for them to go right back to a neutral attitude afterwards.


Animal Crossing, while very simple from a technical perspective, tries very hard to use dialogue and AI effectively. There are only 6 different personality ‘types’ in the game, which over 200 possible villagers can use, but you only ever deal with up to 10 of them at a time, masking the potential repetition. There’s an incredible amount of dialogue, tied to the weather, the time of day, if it’s a special holiday, if the villager is happy or sad… the list goes on. They will even talk to each other, and let you eavesdrop.



To create variation within a single conversation, dialogue trees function perfectly fine in a very controlled way, but the content of a dialogue tree doesn’t often change according to any context other than ‘state of the main plotline’. What’s more, dialogue trees only work if the player is present. Gaming narratives are often incredibly solipsistic – nothing can happen if the player isn’t there to witness or directly affect it, and that’s not how a believable world can function.


The Witcher 2 at the very least uses its dialogue trees in a way less transparent to the player, and with some neat consequences. The small, but incredibly important decision to not display whether a dialogue choice is ‘good’, ‘evil’ or otherwise tied to a game mechanic (which many games are guilty of) means that the player isn’t so easily yanked out of the narrative when making a decision. What you do decide on ends up having further-reaching consequences than just the next line of text, as characters remember how you treated them, and will pass on the word of how much of an asshole you are to their peers.

Taking a cue from Animal Crossing’s book, and having conversation dialogue triggered by the state of the game world, and using Witcher 2‘s system of making sure your decisions are remembered down the line, will obscure some of the ‘branches’ of the dialogue tree from the player’s view. Guy Hasson put forth a theoretical way of managing dialogue trees that operate through more than just what the player does.
For those that don’t warrant complex dialogue trees, there are still solutions to give them variation. Here, randomisation is the key – Procedurally Generated sentences. What’s that? Well, since sentences (in any language) have a logical structure, having a computer construct unique utterances from word and phrase banks will save you from ever hearing a “Welcome to Cornelia!” more than once. It’s a solution that rules out voice acting (it’s hard to get artificially constructed voice sample utterances sounding convincing without some heavy editing and knowledge of phonetics), but it still has a definite future in RPGs.

AI and the ‘Simultaneous Story’ 

Animal Crossing and The Sims use AI in a way that creates robust characters, but they can act freely in a game with no overarching narrative. This isn’t to say that those games should adhere to a plotline (the spinoff Sims games that do are… tepidly received), but the big ‘future of video game AI’ lies in the combination of the two.


The key to more convincing, immersive worlds is that it doesn’t expressly revolve around you. Other characters doing their own thing independently of you are only the start. If these characters actually acted out their own stories incidental to your actions, it would be an implementation of subplots on a scale that books and movies definitely can’t match.

It’s an old title, but The Legend of Zelda: Majora’s Mask is a very well-made example of a ‘simultaneous story’. Almost every character in the game has an intricately detailed life and schedule. Thanks to the strict three day timeframe the game takes place in, the NPCs can be given pre-programmed daily schedules, so their lives can unfold out around the player.

This is where the line between story writing and AI crafting is blurred a little. With the technology available at the time, having the characters act uniquely and randomly would be too much for the poor old N64, but by framing the NPC actions around set narratives, the amount of AI coding was a lot less intense, and the player has the ability to visit the same events again and again from different perspectives (as they learn more about the plot as a whole).

The Dead Rising titles all function on an in-game clock, with game events tied to it. Plot events will happily occur without you if you aren’t there to intervene, resulting in missed plotlines to major changes like characters dying. The first Dead Rising was incredibly strict with its time limit, making it nearly impossible to see absolutely everything in one run (you are, after all, a reporter – not a superhero). It’s a shame that then, for the most part the survivors you encounter are there to be escorted to safety, and not too much else.

AI and the Visual Novel 

I feel like a side mention should go out to the Visual Novel. As the name suggests, it hugs a lot closer to literary storytelling, and for the most part forego AI in its entirety. Likewise, Point ‘n’ Click Adventure games are the text adventures of yore with a graphical polish. This gives them a lot of flak from consumers and critics – how could a genre survive when, in terms of technology, they are so undemanding?


Interestingly, that may be their strength. They are the Dialogue Tree to the extreme – everything is precisely controlled and scripted. But with that, it also means that there is so much more room to write their plots and characters as carefully as possible. They have no veneer of complex gameplay, and often can’t hide behind flashy graphics. The Ace Attorney games and the Monkey Island series contain some of the most complex characters in gaming, at least in terms of background detail and motivation. If any genre is to go the distance in creating deep and empathic NPCs within a narrative, you bet it’ll be a Visual Novel or an Adventure Game.



That, however, doesn’t mean that AI can’t make them more robust experiences. What the characters do when the player isn’t talking to them is just as important as the face-to-face chatting. Christine Love proved that with the background-running social networking in ‘don’t take it personally babe, it just ain’t your story’. Dating Sims corner the market on major characters that interact with the player in ways other than dialogue trees (meaning statistically, not carnally you pervert), but NPCs having a ‘memory’ for what you do and say would be both a lot more involved, and avoids simplifying the nature of relationships to “Choose dialogue option B”.


The future of AI

So what’s happening next in the world of video game AI? Well, if you have the free time, take a look at Prom Week, a cute flash game that takes up the idea of generated conversations, and lets you experiment with them, reminiscent of The Sims, but with actual dialogue. Designed by Mike Treanor and a small crew of game designers from Santa Cruz university, it constructs sentences to feel unique, based on context, and how interacting characters feel about each other. The game challenges you to set up the characters to certain goals, but it’s still relatively easy to orchestrate the right outcomes since the behaviour feels so genuine.


Prom Week is about its AI system through and through, but you only need aspects of its concept to bring an old game somewhere new. Imagine if LA Noire remembered the reputation you made for yourself; carrying out your investigations kindly, with ruthless efficiency, or like an Actual Cop.

The biggest AI breakthroughs are going to take a long time, and it might take even longer to use them to craft a game world that tells a really great story. A game where the subplots both operate independently of the player, but are also organically reflecting the player choices is a risky, big budget venture. And NPC that truly feels like a person when held up to the cold harsh light of gameplay may never even happen. But I remain hopeful. One day then, my enjoyment of video game stories won’t feel so sordid.

Read on to Final Comments.