Game Development Reference
In-Depth Information
Known-good numbers are a great thing, but because games are an entertainment
product, accurate numbers are not actually required. If the AI plays well with a
warped view of its world, there is no inherent problem. The effort required to
validate the actual numbers is likely to be substantial and in the long run may not
be worthwhile. This brings us to our third method of getting the numbers, which
is to simply fake it.
Faking It
Somewhere between random selection and a good set of precomputed odds is the
age-old method of faking it. The fact that experience helps is no comfort to the
beginning AI programmer, but the beginner should also take heart in the fact that
even experts sometimes fake it. All numbers are subject to tuning, so the sooner
tuning begins, the better. Faking it means having numbers ''as soon as the dart
hits the dartboard,'' which can happen well before the first line of instru-
mentation code is ever written. Usually, the first set of numbers is thought to be
reasonable in some sense by the person making them up. Fewer people turn to a
life of daily crime than go to a day job. What is ''fewer'' in actual numbers: 1 in
10? 1 in 1,000? 1 in 100,000? The numbers from current real life in a first-world
country may not match the number from The Sims , and that number is probably
different from Grand Theft Auto . Games are an entertainment product, so the
numbers only have to be right for your game . Faking it starts by being within one
or two zeroes of the final number.
For a beginner, the most serious drawback to faking it and tuning as you go is
that tuning can take forever. Hard numbers (or anything close to hard numbers)
place bounds on the tuning problem and guide the effort. A hybrid approach is to
start by faking it as best you can. Instrumentation is designed into the game, and
tuning is guided by the hard numbers as soon as they are available.
For the experienced AI programmer, faking it is actually quite liberating. Tables
of numbers can be easier to tune than files of code. The AI does not have to be
perfectly rational; it can think that the game world works differently than it
actually does. In fact, the AI programmer can negotiate with the game designer
how the game world should actually work, because that reality is just as mutable
as the AI. Not only is the AI being tuned for maximum entertainment value, but
so is the rest of the game world. The equations and mathematics used by
experienced AI programmers to get their numbers is a book in its own right
[Mark09] and will not be covered here.
Search Nedrilad ::

Custom Search