Controlling Players and Characters(4)

Controlling Players and Characters(4)

 

Character Classes


Characters come in all shapes and sizes—big ones, little ones, even short and furry
ones. The fact is that some characters have different attributes that make them special.

For every different type of character in your game, there is a matching character
class. You can think of character classes as being a way to differentiate the different
species of characters in your game. Going even further, classes can determine a
specific type of character in a species.

Classifying a character simply as human isn’t enough. Instead, the classification of
human fighter might be appropriate in certain cases. This applies to all characters.
For example, you might classify a dragon as an ice dragon, or a fire dragon, or a
rock dragon, and so on.

The reasons for determining class are important to your game design . The items in your
game are assigned a class usage variable that states which classes can harness a particular item.
Broadswords can be wielded only by human or dwarf warrior characters, whereas only a wizard
class can use a spell scroll.

Character classes also come into play when you are handling combat situations.
Certain attacks, whether physical or magical, have either a strong or weak effect on
specific character classes. Consider, for example, a fireball spell. Although a fireball
is heat-based, it will do much more damage to an ice-based monster than to a firebased
monster (in fact, it might heal a fire-based monster).

Character classes are assigned by number and are entirely up to your design.

 

Character Actions

Every character in your game has an associated set of actions that the character
can perform, and with action, an associated animation is played out on the screen.
Taking a swing with a weapon, casting a spell, or talking to another character—
they’re all actions, and it’s your job to determine what actions your game’s
characters can perform.

Each action in the game also has a resulting effect. A walking action moves a character,
whereas an attack action involves swinging a weapon and determining who or
what is hit. Internally, one effect is taking place; externally, the player is treated to a
graphical animation to represent the action.

Controlling Players and Characters(4)_第1张图片

Certain actions can be performed only at specific times. Maybe characters can’t
attack during navigation sequences, leaving combat actions to a separate battle
sequence. Even when those actions are acceptable to use, another factor limits
when some actions can be performed.

Take the attack action for example. Assuming that it can be performed at any time
during the game doesn’t mean that the player can sit and constantly hack away. You
use a limiting factor called the charge to delay the time between attacks. In fact, all
actions except idle and movement work off the character’s charge.

Whenever one of those actions is used, the character’s charge is reset. Slowly, that
charge refills until the character is once again able to perform another action. The
rate at which this charge increases is specific to each type of character.

Although every character in the game can perform the actions shown in Table
16.4, different types of characters use only certain actions. PCs are the only ones
who use items, for example, so a monster will never be assigned that action.

To better understand what each character type is capable of performing, take a
brief look at each one of them.


你可能感兴趣的:(Controlling Players and Characters(4))