While playing old console games you must have realized that their is a common control pattern for almost every game. For example the general use of D-pad is for character movement and buttons can be used for various actions. In touch smartphones, we have control options like TILT, SWIPE and TOUCH for performing such actions. There is a benefit of mapping these actions on native controls. You can connect a game controller to your android device and can extend the gaming experience gracefully. Some controllers are available in the market like Xbox 360 controller, Logitech wireless Gamepad F710. Also some bluetooth game controllers are available on which you can mount the device and have a console gaming experience.
When you press a key on controller or keyboard, an event is generated known as KeyEvent. You can have a look over here to check the list of various android keyevents. While developing a game, you can map the game actions along with these keyevents as well as TILT, SWIPE and TOUCH. There are some standards defined by Sony for Xperia Play. Click here for more details. You can use these predefined standards for enhancing your gaming experience.
The benefits of mapping native android controls in your games are as follows.
- You can play android games by using a keyboard.
- Various controllers can be used for playing android games flawlessly.
- There is a chance of your games getting listed in catalogs of various android console markets.