Game Development Reference
In-Depth Information
WARNING
It's important that you make your entire game controllable via a gamepad if you chose to
support one in your game. That means that everything from starting the game to navigat-
ing menus should all work with the controller. The last thing you want players to do is put
down the controller in a pause screen or to start the game. This means adding a little extra
logic to your game's UI, but one of the tricks I use is to also map these controls to the
keyboard so you can support both and the user doesn't have to touch the mouse if there is
no need to.
Knowing When to Use What
As you can see, all of this can really be overwhelming. I have put together scenarios to help
you pick when to support touch or physical (see Table 4-2 ).
Table 4-2. Windows 8 Game Controls Cheat Sheet
Support
Physical
Controls
Support
Touch
Controls
Input
Type
Support
Controller Notes
Keyboard Yes
No
No
Only support keyboard and hide virtual controls
Mouse
Yes
Possibly
NA
Mouse can activate touch controls if you have a vir-
tual joystick but may not want to show if using virtu-
al D-pad
Touch
No
Yes
No
Ignore physical controls when working with touch
events
Controller No
No
Yes
Ignore all other input types when using a controller
Table 4-2 should help you break out your controller logic to be more contextual to what a
user would expect based on the type of input they are using. Of course, you can simply keep
touch controls on the entire time and always check for a physical controller, but a big part of
publishing any game is the level of polish you add to the final product. It would be silly to
see touch controls on a desktop with no touch screen at all.
Search WWH ::




Custom Search