Game AI: Beauty and the Beast

Alex J. Champandard on August 8, 2007

Artificial intelligence has come a long way, but yet it’s still far off from meeting our expectations. This is most visible in modern video games, which suggests game AI is not an easy problem to solve either — regardless of whether we “cheat” or not!

A Beast Holding a Rose

Sure, game AI always relies on specific tricks, but the whole process is no easier than building traditional AI decision-making and control systems. Compare having to create the brain of an actor playing the role of a character instead of the brain of the character in the first place. Which is easiest?

To accomplish our goal of realistic and entertaining game characters, there are few shortcuts we can take. From that perspective, it’s important to get the basics right…

Why Game AI Sucks

Game AI hasn’t met expectations for the very same reason artificial intelligence has struggled to deliver on its promise. The problem is that, as software developers, we have trouble building reliable systems — let alone ship them on time. So what chance do we have of building an intelligent system if basic development techniques are still a problem? (Let’s be pragmatic here!)

“We can hardly create reliable systems, so how can we build intelligent ones?”

This issue is particularly obvious in the computer games industry. Flagship titles are regularly delayed because of programming challenges. Sure, software is getting more complex, but the main issue is that we’re very bad at handling this complexity.

We’ve been researching computer science for over half a century, but it seems we’re still missing certain skills when it comes to building software. So-called “agile” methodologies are certainly a step forward, but lessons learned decades ago in building robust and extensible systems are lost on most mainstream programmers nowadays. Those of you still programming in Smalltalk, Lisp/Scheme or even Forth know this.

Why Artificial Intelligence Rocks

“If complexity is the beast, beauty lies in solving small problems perfectly.”

Over the decades, researchers in AI have managed to crack most specific problems, ranging from high-dimensionality pattern recognition to control systems that are reactive and purposeful. There are many solutions out there for pretty much any kind of problem.

In fact, most of the advanced techniques used in mainstream development today originate from AI research:

  • Knowledge representation

  • Relational databases

  • Search algorithms

  • Finite state machines

  • Rule-based systems

AI hasn’t had that many triumphs because anything successful becomes computer science! In this case, what’s the next step for AI, and how does this help with game development?

Putting The Pieces Together

It seems that what’s missing isn’t a grand unifying theory of AI, but our ability to assemble all these intelligent solutions into one system. In a sense, that defines the problems with game AI too: how can we go beyond combining a path-finder with some terrain analysis, and adding a behavior tree or a simple planner on top?

Ultimately, in order to scale up the complexity and build intelligent systems, we’re going to have to focus on development practices, and building great tools that:

  • Allow us to solve many domain specific problems modularly.

  • Provide an easy way to connect these solutions together sensibly.

I find this exciting and challenging at the same time for two reasons:

  1. We’re not far away from being able to do that; there’s lots of low hanging fruit.

  2. This is going to require combining the logic of classical AI with the more modern AI techniques.

With that in place, we’ll be able to build large intelligent systems, or many small ones that interact together. Then, most of our dreams of AI, and game AI should fall into place easily. Well, at least it’s worth a try

This editorial was written by Alex J. Champandard as part of the Blog Round Table on Artificial Intelligence in Games.

Discussion 0 Comments

If you'd like to add a comment or question on this page, simply log-in to the site. You can create an account from the sign-up page if necessary... It takes less than a minute!