Game Development Reference
In-Depth Information
FIGURE 8.2
The Sony SIXAXIS
controller
The D-pad gives the player a crude level of control over a vehicle or avatar; she is
able to make the vehicle move in any of the eight major directions but not in any
other. You should use D-pads for directional control only if you have no better
device available. D-pads do remain useful alongside a joystick; you can assign func-
tions to the D-pad that require less subtle control, such as scrolling the main view
window in one of the eight directions, which leaves the joystick free for such tasks
as avatar navigation control.
JOYSTICKS
A joystick is a single vertical stick anchored at the bottom that can be tilted a
limited amount in any direction. The joystick is spring-loaded and returns to its
central position if the player lets go of it. When the game software checks the posi-
tion of the joystick, it returns two absolute data: an X-value indicating tilt to the
left or right, and a Y-value indicating the tilt forward or back.
NOTE Modern joy-
sticks built for use with
combat flight simula-
tors may include a
large number of other
controller buttons as
well. All these ulti-
mately amount either
to binary buttons or
sliders. This section is
concerned only with
the tilting action of the
basic device.
A joystick offers a finer degree of control than a D-pad does. The Sony SIXAXIS
controller in Figure 8.2 features two small joysticks (the circular objects at the bot-
tom) as well as a D-pad.
Joysticks make ideal steering controls for vehicles. To return to a default activity—
flying straight and level, for instance—the player only has to allow the joystick to
return to the neutral position. Since joysticks may travel only a limited amount in
any direction, they allow the player to set a direction and a rate of movement. The
UI interprets the degree of tilt as indicating the rate. For instance, moving a joy-
Search WWH ::




Custom Search