Chapter 5: User Interface Programming and Input Devices


Overview

Any game programmer who wants to remain being a game programmer for very long quickly needs to master the art of developing great user interfaces so that players can better interact with their games. The trick to building successful interfaces is to make sure that the interface really matches the format and complexity (or simplicity) of the game you are building. For example, an interactive movie-style game such as Wing Commander III can get away with a simple interface that basically operates (and looks like) Windows Media Player. After all, for this game you only need to play, pause, rewind, and whatnot. If all games could be that simple we'd have it made in the shade!

The game that you're developing might need nothing more than a gamepad, or it might require something more complicated, such as user selectable mouse and joystick controls with keyboard hotkeys. In any case, you need to have a clue how to grab the input from these devices and how to map these events to bits of code that change the state of your game.

Because processing user input is such an important component of user interfaces (especially with interactive games), I'm going to spend a bit of time up front in this chapter covering input devices. My personal feeling is that if you have a mastery of input devices you'll be about 80% closer to being able to build good interfaces. After exploring input devices we'll move up a level and discuss the components that are required to create functional interfaces for games.




Game Coding Complete
Game Coding Complete
ISBN: 1932111751
EAN: 2147483647
Year: 2003
Pages: 139

Similar book on Amazon

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net