The ubiquitous omniscient red eyeball of the HAL-9000 computer loomed over a primitive 2D representation of a chess board. Astronaut David Bowman contemplated his next move, distracted. For movie audiences in the 1960s, the idea of a computer that could play chess was mind-blowing, a sure sign of higher intellectual function.

Of course these days a powerful chess computer could fit in your pocket. Ten years ago the IBM computer Deep Blue beat the best human chess player in the world. In many ways, chess has been "solved" as an artificial intelligence problem.

Here's a much fuzzier problem: how do you get a computer to play a game of Civilization IV? Here, the object isn't necessarily to "win" the game, but rather -- like the ladies on the bathroom wall -- to show the player a good time. This was the subject of game designer Soren Johnson's speech at the 2008 Game Developers Conference.

Exploring the different goals of game AI

"Good AI" vs. "Fun AI"

So what's the difference between a chess computer and Civilization's virtual Mahatma Gandhi? Johnson looks at game AI as belonging somewhere on a spectrum. At the left end of the spectrum is "Good AI." That's when a computer plays a game with fixed rules, and it plays to win. Like a good chess AI.

At the opposite end of the spectrum you'll find "Fun AI." Here the AI is player-focused. The example Johnson gave is the AI for the popular flash game Desktop Tower Defense. The "intelligence" that guides the creeps slinking around the map in that game is laughable. They're simply there to create an interesting puzzle for the player.

With those constraints in mind, the differences between the two types of AI -- and the games you'll find them in -- is clear. Good AI tends to be based around multiplayer games, with a fixed rule set and equally-matched sides. You never want Good AI to cheat, certainly, and (unless it's a training program) you want it to use all available tactics. The quality of Good AI is objective and easily measurable: how well does it play the game? And in most cases the Turing Test is relevant: for example, a good chess-playing computer should be indistinguishable from a good human player in a blind test. In short, Good AI plays to win.

That's a sharp contrast to Fun AI, which you'll find in very different games. Fun AI is mostly for single-player games, with unevenly-matched sides. Even if it doesn't outright cheat, the AI probably plays with different rules than human players. It usually uses a limited set of available tactics. It's hard to measure the success of a Fun AI, as it's subjective. The Turing Test is irrelevant; nobody would think that the monsters in Desktop Tower Defense are controlled by people, or certainly, not anyone you'd like to meet. In short, Fun AI plays to lose.