Game Development Reference
In-Depth Information
Like war games, team sports games are good candidates for using hierarchical finite
state machines to produce the artificially intelligent behavior required. Two-player
sports can use simple finite state machines, one for each player. See the discussion
on finite state machines at the end of Chapter 14, “Strategy Games.”
Injuries
I wouldn't ever set out to hurt anybody deliberately unless it was, you know, important—
like a league game or something.
—D ICK B UTKUS , NFL LINEBACKER
Injuries are a sad but common side effect of sports, and serious simulations take
them into account. Because injuries occur somewhat randomly, they're outside the
player's control and can be frustrating. Most sports games allow the players to turn
off injuries if they don't like the effect that injuries have on the game.
Although it's possible for an athlete to injure herself simply by running or jumping,
this doesn't provide the player with any visible explanation for why the injury
occurred. A lot of sports games therefore limit injuries to cases of some kind of col-
lision, ordinarily between two athletes. To determine whether an injury occurs, you
should include such factors as the relative speed of the two athletes, their weights,
their respective susceptibilities to injury, and a random probability just to introduce
some uncertainty into the situation. The heavier an athlete is, the more force she
imparts in a collision, and it is the force that does the damage to the other athlete.
The stress of playing some positions, such as pitching in baseball, can injure an
athlete without a collision, with injuries becoming more likely the longer the
pitcher stays in the game. You can compute the probability of an injury on every
pitch and raise the probability slightly with each ball thrown.
You can also decide which part of the body sustains the injur y and the length of
time for which it will disable the athlete. Study reports of injuries and recovery
times for the sport you are simulating. If your game tracks athletes over a period
of time, you should consider the cumulative effect of injury and recovery time on
their careers.
Arcade Mode Versus Simulation Mode
Switching into arcade mode skews the play toward lots of action and relatively few
slow-paced game states, such as strikeouts or walks. Arcade mode makes the game
more exciting at the expense of realism; simulation mode makes it a more accurate
simulation of the real sport at some expense in fun. In baseball, for example, an
athlete does well to achieve a .333 batting average—that is, gets a hit only once for
every three at bats. Some players may find that a little dull. Switching the game to
arcade mode could let the player get a hit 50 percent of the time or even more. In
American football, you can artificially increase the number of completed passes by
Search WWH ::




Custom Search