hoa_input::private_input::JoystickState Class Reference

Retains information about the user-defined joystick settings. More...

#include <input.h>

Collaboration diagram for hoa_input::private_input::JoystickState:

Collaboration graph
[legend]
List of all members.

Public Attributes

int32 joy_index
 An index to the SDL joystick which should be made active.
SDL_Joystick * js
 A pointer to the active joystick.
Generic button names.
uint8 cancel
uint8 confirm
 Each member retains the index that refers to the joystick button registered to the event.
uint8 left_select
uint8 menu
uint8 pause
uint8 quit
uint8 right_select
uint8 swap
Current Peak Joystick Axis Values
int16 x_current_peak
 These variables retain the current peak value of each joystick axis.
int16 y_current_peak
Previous Peak Joystick Axis Values
int16 x_previous_peak
 These variables retain the previous peak value of each joystick axis.
int16 y_previous_peak

Friends

class GameInput

Detailed Description

Retains information about the user-defined joystick settings.

***************************************************************************

This class is simply a container for various SDL structures that represent the joystick input. Because joystick axis movement is not a simple "on/off" state as opposed to keys, we need a little extra logic so that it can be represented as such. In the range of possible joystick values (-32768 to 32767), we section off the region into thirds and label any crossing of these 'boundaries' as state changes.

Definition at line 99 of file input.h.


Friends And Related Function Documentation

friend class GameInput [friend]

Definition at line 143 of file input.h.


Member Data Documentation

uint8 hoa_input::private_input::JoystickState::cancel

Definition at line 114 of file input.h.

Referenced by hoa_input::GameInput::_JoystickEventHandler(), hoa_input::GameInput::_SetNewJoyButton(), hoa_input::GameInput::GetCancelJoy(), hoa_input::GameInput::RestoreDefaultJoyButtons(), hoa_input::GameInput::SetCancelJoy(), and hoa_input::GameInput::SingletonInitialize().

uint8 hoa_input::private_input::JoystickState::confirm

Each member retains the index that refers to the joystick button registered to the event.

Definition at line 113 of file input.h.

Referenced by hoa_input::GameInput::_JoystickEventHandler(), hoa_input::GameInput::_SetNewJoyButton(), hoa_input::GameInput::GetConfirmJoy(), hoa_input::GameInput::RestoreDefaultJoyButtons(), hoa_input::GameInput::SetConfirmJoy(), and hoa_input::GameInput::SingletonInitialize().

int32 hoa_input::private_input::JoystickState::joy_index

An index to the SDL joystick which should be made active.

Definition at line 105 of file input.h.

Referenced by hoa_input::GameInput::SingletonInitialize().

SDL_Joystick* hoa_input::private_input::JoystickState::js

A pointer to the active joystick.

Definition at line 102 of file input.h.

Referenced by hoa_input::GameInput::EventHandler(), hoa_input::GameInput::GameInput(), hoa_input::GameInput::SingletonInitialize(), and hoa_input::GameInput::~GameInput().

uint8 hoa_input::private_input::JoystickState::left_select

Definition at line 117 of file input.h.

Referenced by hoa_input::GameInput::_JoystickEventHandler(), hoa_input::GameInput::_SetNewJoyButton(), hoa_input::GameInput::GetLeftSelectJoy(), hoa_input::GameInput::RestoreDefaultJoyButtons(), hoa_input::GameInput::SetLeftSelectJoy(), and hoa_input::GameInput::SingletonInitialize().

uint8 hoa_input::private_input::JoystickState::menu

Definition at line 115 of file input.h.

Referenced by hoa_input::GameInput::_JoystickEventHandler(), hoa_input::GameInput::_SetNewJoyButton(), hoa_input::GameInput::GetMenuJoy(), hoa_input::GameInput::RestoreDefaultJoyButtons(), hoa_input::GameInput::SetMenuJoy(), and hoa_input::GameInput::SingletonInitialize().

uint8 hoa_input::private_input::JoystickState::pause

Definition at line 119 of file input.h.

Referenced by hoa_input::GameInput::_JoystickEventHandler(), hoa_input::GameInput::_SetNewJoyButton(), hoa_input::GameInput::GetPauseJoy(), hoa_input::GameInput::RestoreDefaultJoyButtons(), hoa_input::GameInput::SetPauseJoy(), and hoa_input::GameInput::SingletonInitialize().

uint8 hoa_input::private_input::JoystickState::quit

Definition at line 120 of file input.h.

Referenced by hoa_input::GameInput::_JoystickEventHandler(), and hoa_input::GameInput::SingletonInitialize().

uint8 hoa_input::private_input::JoystickState::right_select

Definition at line 118 of file input.h.

Referenced by hoa_input::GameInput::_JoystickEventHandler(), hoa_input::GameInput::_SetNewJoyButton(), hoa_input::GameInput::GetRightSelectJoy(), hoa_input::GameInput::RestoreDefaultJoyButtons(), hoa_input::GameInput::SetRightSelectJoy(), and hoa_input::GameInput::SingletonInitialize().

uint8 hoa_input::private_input::JoystickState::swap

Definition at line 116 of file input.h.

Referenced by hoa_input::GameInput::_JoystickEventHandler(), hoa_input::GameInput::_SetNewJoyButton(), hoa_input::GameInput::GetSwapJoy(), hoa_input::GameInput::RestoreDefaultJoyButtons(), hoa_input::GameInput::SetSwapJoy(), and hoa_input::GameInput::SingletonInitialize().

int16 hoa_input::private_input::JoystickState::x_current_peak

These variables retain the current peak value of each joystick axis.

Definition at line 139 of file input.h.

Referenced by hoa_input::GameInput::_JoystickEventHandler(), and hoa_input::GameInput::EventHandler().

int16 hoa_input::private_input::JoystickState::x_previous_peak

These variables retain the previous peak value of each joystick axis.

Definition at line 129 of file input.h.

Referenced by hoa_input::GameInput::EventHandler().

int16 hoa_input::private_input::JoystickState::y_current_peak

Definition at line 140 of file input.h.

Referenced by hoa_input::GameInput::_JoystickEventHandler(), and hoa_input::GameInput::EventHandler().

int16 hoa_input::private_input::JoystickState::y_previous_peak

Definition at line 130 of file input.h.

Referenced by hoa_input::GameInput::EventHandler().


The documentation for this class was generated from the following file:
Generated on Fri Jul 6 23:14:34 2007 for Hero of Allacrost by  doxygen 1.5.1