Game Development Reference
usually raised by those with the least industry experience and quickly put to rest
by those with many years of experience. The conventional wisdom is that neural
networks are not used in commercial games. By contrast, genetic algorithms have
gained a very modest toe-hold into game AI, but not in the manner that you
might first expect, as we shall see. A major goal of this section is to give beginning
AI programmers sufficient knowledge and willpower to enable them to resist
using either method lightly.
Before considering the different machine-learning algorithms, it is worthwhile to
consider how they will be used. The first big question to ask of any proposed
game feature is, ''Does it make the game more fun?'' If cool techniques do not
translate into improved player experience, they do not belong in the game.
The next big question to answer is, ''Will it learn after it leaves the studio?'' For
most machine learning used in games, the answer is a resounding ''No!'' Quality-
assurance organizations do not want support calls demanding to know why the
AI suddenly started cheating or why it suddenly went stupid. In the first case, the
AI learned how to defeat the player easily; in the second case, the AI learned
something terribly wrong. Most ordinary car drivers are happy with the factory
tuning of their real-world automobiles, and most players are fine with carefully
tuned AI. That being said, the answer is not always ''No''; Black & White is an
early example of a game that turned machine learning in the field into a gameplay
Learning algorithms are susceptible to learning the wrong thing from outlier
examples, and people are prone to the same mistake. Black &White learned in the
field, and learning supported a core gameplay mechanic. One of the main fea-
tures of the game was teaching your creature. If teaching is part of the gameplay,
then learning is obviously an appropriate algorithm to support the gameplay.
Howmany games can be classified as teaching games? Most games do not employ
teaching in their gameplay, and most of those same games have no need of
learning algorithms. There may be other gameplay mechanics besides teaching
that are a good fit for machine learning in the field, but it will take an innovative
game designer backed by a good development team to prove it.
The final question always to ask is, ''Is this the right tool for this job?'' For neural
networks in game AI, the answer is usually an emphatic ''No.'' In some cases
involving genetic algorithms, the answer will be a resounding ''Yes.'' One of the
clarifying questions to ask is, ''Is it better to teach this than it is to program it?''