Story Mechanics as Game Mechanics: Applying Story Analysis Techniques to Game ArtificiaI Intelligence
by Chris R Fairclough
In the new millennium computer games seem to be more accepted than ever, just another element of modern culture. However, there could be something different about their potential that fundamentally separates them from other media. The interactivity of the medium has been harnessed to a certain degree, and games publishers are wary of games that are overly interactive as this involves a lot more play-testing, but the new medium has the possibility of blurring the boundary between artists and the art they create.
The research field of Artificial Intelligence (AI) has encompassed a series of more or less discrete approaches including neural networks, genetic algorithms, expert (rule-based) systems, machine learning techniques such as reinforcement learning, and case-based (memory-based) reasoning. These are based on cognitive and biological theories and most are good at certain specialised types of tasks, much like different parts of the brain, and different people, are good at certain types of tasks. When it comes to creativity, however, all of these techniques are left in the dust by the human mind, and it is generally assumed that creative AI is a holy grail that is not, and perhaps should not, be possible in the near future. I would contend that it is a generalised AI, that can operate in many domains, that is the far off dream of researchers, but a creative system that operates in a strictly limited domain is within the grasp of today's technologies. This sort of creative system would need a combination of a variety of different techniques working together to simulate a human's creative processes within a specific domain, and thus extend the programmer-as-artist's effective reach, into the control of the reaction of the artwork to its audience.
The gameAI group at Trinity College Dublin is researching the use of academic AI techniques in computer games. In my current work, the story analysis approach of Vladimir Propp has been built on to create a storytelling system which works on the principle that new stories can be created by combining story elements from different stories, and retelling old stories with different characters and different causal chains of events. This is achieved using a case-based reasoning system, and an expert system, combined within a story director agent. The story director has as input, a case library of story structures, the current state of a game world including the player state and non-player character (NPC) states, and a history of previously played out story events. The output is a continuously updated list of story goals, each of which are played out in a dynamic, flexible way by the NPCs. NPCs autonomously react to the player and other NPCs in a consistent manner, remembering events and executing social simulation behaviour. The story goals are assigned to NPCs based on the dynamic state of these social (and anti-social) models, so that the type of goal to be executed is consistent with the character state. In this way, a consistent, causal, chain of events is seen by the player as the driving force of a plotline that is generated on the fly.
The opinion that stories and games are fundamentally incompatible is out of date, after the success of many games that blend the two to create something that is different to both concepts. Half Life 2, Fable, Doom 3, and more games are coming out that will set new standards in story-based game A.I. There is also a new breed of multiplayer online games that pose a different challenge to game developers: How to create the same immersive story-based gameplay found in successful single player games within a huge, multiplayer, non-linear game world. In this context a story cannot be completely pre-scripted while allowing the freedom of movement and action inherent in these games. The encoding of story telling techniques in the game engine, at a game mechanics level, is necessary to allow the NPCs in such a game to behave consistently with all the players they encounter, while still engaging with them at a story level. To accomplish this task, it seems, a sophisticated A.I. director needs to operate on both the server and client side, to monitor each player's actions, and coordinate the NPCs goals in a consistent manner.
Of course, perhaps the players of these online games don't want some AI-generated plot director interfering with their nicely planned out objective - directed gameplay, and maybe the series of events that naturally occur between players and NPCs, based on the character interactions alone, can be viewed as a story, but - the age-old folktale and mythical plot structures that haunt human culture from ages past have manifested themselves in every new medium that comes along, so I, for one, don't expect these online worlds to suffer any other fate.
Michael Mateas' Interactive Story Links: http://www.quvu.net/interactivestory.net/links.html
Chris Fairclough, Trinity College Dublin/Irish University Consortium