shadowislord / radakan

Radakan is a single-player RPG in a dark dynamic setting, driven by a freedom-of-choice environment, with a focus on true role-playing instead of combat.
http://radakan.org/
2 stars 0 forks source link

Create input system #27

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
The input system is located in GameInputManager.

Functionality is as follows:
GameInputManager is a key, mouse and joystick listener. All input events
must go through the GameInputManager. 

NOTE: The intricate details of the functionality are not included, it has
yet to be decided for an efficient and clean way of passing input events
around. 

Original issue reported on code.google.com by ShadowIs...@gmail.com on 17 Nov 2008 at 6:32

GoogleCodeExporter commented 9 years ago

Original comment by ShadowIs...@gmail.com on 17 Nov 2008 at 6:33

GoogleCodeExporter commented 9 years ago
The basic layout was decided for this system. 

Mappings to various inputs are stored in the game config. Mappings generate
ActionEvents, interested parties can receive notifications of ActionEvents by
registering an InputActionListener in the input manager. 
An ActionEvent specifies a floating point value 'velocity' indicating the delta 
(for
mouse movement and wheel), 0 or 1 (for buttons) or the current axis value 
(joystick).
Negative values represent their own input action, e.g negative mouse movement 
along
the X axis is different from positive movement along the X axis.

Original comment by ShadowIs...@gmail.com on 17 Nov 2008 at 7:53