Trees | Indices | Help |
|
---|
|
PyObjectPlus --+ | CValue --+ | SCA_ILogicBrick --+ | SCA_ISensor --+ | SCA_JoystickSensor
This sensor detects player joystick events.
Properties:
|
|||
list |
|
||
bool |
|
||
Deprecated | |||
---|---|---|---|
integer |
|
||
|
|||
list |
|
||
|
|||
list |
|
||
integer |
|
||
|
|||
integer |
|
||
|
|||
list |
|
||
list |
|
||
|
|||
integer |
|
||
integer |
|
||
integer |
|
||
bool |
|
||
Inherited from SCA_ISensor | |||
|
|||
integer |
|
||
|
|||
boolean |
|
||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
Inherited from SCA_ILogicBrick | |||
integer |
|
||
KX_GameObject |
|
||
|
|||
Inherited from CValue | |||
string |
|
||
Inherited from PyObjectPlus | |||
bool |
|
|
|||
[integer, integer] |
axis The axis this sensor reacts to, as a list of two values [axisIndex, axisDirection] axisIndex: the axis index to use when detecting axis movement, 1=primary directional control, 2=secondary directional control. |
||
int |
axisSingle (read-only) like axisValues but returns a single axis value that is set by the sensor. |
||
list of ints |
axisValues (read-only) The state of the joysticks axis as a list of values numAxis long. |
||
integer |
button The button index the sensor reacts to (first button = 0). |
||
boolean |
connected (read-only) True if a joystick is connected at this joysticks index. |
||
[integer, integer] |
hat The hat the sensor reacts to, as a list of two values: [hatIndex, hatDirection] hatIndex: the hat index to use when detecting hat movement, 1=primary hat, 2=secondary hat (4 max). |
||
int |
hatSingle (read-only) like hatValues but returns a single hat direction value that is set by the sensor. |
||
list of ints |
hatValues (read-only) The state of the joysticks hats as a list of values numHats long. |
||
integer |
index The joystick index to use (from 0 to 7). |
||
integer |
numAxis (read-only) The number of axes for the joystick at this index. |
||
integer |
numButtons (read-only) The number of buttons for the joystick at this index. |
||
integer |
numHats (read-only) The number of hats for the joystick at this index. |
||
integer |
threshold Axis threshold. |
||
Inherited from SCA_ISensor | |||
---|---|---|---|
int |
frequency The frequency for pulse mode sensors. |
||
boolean |
invert Flag to set if this sensor activates on positive or negative events. |
||
boolean |
level Option whether to detect level or edge transition when entering a state. |
||
boolean |
positive True if this sensor brick is in a positive state. |
||
boolean |
tap When enabled only sensors that are just activated will send a positive event, after this they will be detected as negative by the controllers. |
||
boolean |
triggered True if this sensor brick is in a positive state. |
||
boolean |
useNegPulseMode Flag to turn negative pulse mode on and off. |
||
boolean |
usePosPulseMode Flag to turn positive pulse mode on and off. |
||
Inherited from SCA_ILogicBrick | |||
int |
executePriority This determines the order controllers are evaluated, and actuators are activated (lower priority is executed first). |
||
string |
name The name of this CValue derived object (read-only). |
||
KX_GameObject or None in exceptional cases. |
owner The game object this logic brick is attached to (read-only). |
||
Inherited from PyObjectPlus | |||
bool |
invalid Test if the object has been freed by the game engine and is no longer valid. |
|
|
Deprecated: Use the index attribute instead. |
Deprecated: Use the index attribute instead. Note: This is only useful when you have more then 1 joystick connected to your computer - multiplayer games. |
Deprecated: Use the axis attribute instead. Note: When the "All Events" toggle is set, this option has no effect. |
Deprecated: Use the axis attribute instead. Note: When the "All Events" toggle is set, this option has no effect. |
Deprecated: Use the axisValues attribute instead. Note: Some gamepads only set the axis on and off like a button. |
Deprecated: Use the threshold attribute instead. |
Deprecated: Use the threshold attribute instead. |
Deprecated: Use the button attribute instead. Note: When the "All Events" toggle is set, this option has no effect. |
Deprecated: Use the button attribute instead. Note: When the "All Events" toggle is set, this option has no effect. |
Deprecated: Use the getButtonActiveList method instead. |
Deprecated: Use the hat attribute instead. Note: When the "All Events" toggle is set, this option has no effect. |
Deprecated: Use the hat attribute instead. |
Deprecated: Use the numAxis attribute instead. |
Deprecated: Use the numButtons attribute instead. |
Deprecated: Use the numHats attribute instead. |
Deprecated: Use the connected attribute instead. |
|
axisThe axis this sensor reacts to, as a list of two values [axisIndex, axisDirection] axisIndex: the axis index to use when detecting axis movement, 1=primary directional control, 2=secondary directional control. axisDirection: 0=right, 1=up, 2=left, 3=down
|
axisSingle(read-only) like axisValues but returns a single axis value that is set by the sensor. Only use this for "Single Axis" type sensors otherwise it will raise an error.
|
axisValues(read-only) The state of the joysticks axis as a list of values numAxis long. each spesifying the value of an axis between -32767 and 32767 depending on how far the axis is pushed, 0 for nothing. The first 2 values are used by most joysticks and gamepads for directional control. 3rd and 4th values are only on some joysticks and can be used for arbitary controls. left:[-32767, 0, ...], right:[32767, 0, ...], up:[0, -32767, ...], down:[0, 32767, ...]
|
buttonThe button index the sensor reacts to (first button = 0). When the "All Events" toggle is set, this option has no effect.
|
hatThe hat the sensor reacts to, as a list of two values: [hatIndex, hatDirection] hatIndex: the hat index to use when detecting hat movement, 1=primary hat, 2=secondary hat (4 max). hatDirection: 1-12
|
hatValues(read-only) The state of the joysticks hats as a list of values numHats long. each spesifying the direction of the hat from 1 to 12, 0 when inactive. Hat directions are as follows...
|
indexThe joystick index to use (from 0 to 7). The first joystick is always 0.
|
thresholdAxis threshold. Joystick axis motion below this threshold wont trigger an event. Use values between (0 and 32767), lower values are more sensitive.
|
Trees | Indices | Help |
|
---|
Generated by Epydoc 3.0beta1 on Wed Aug 26 12:07:42 2009 | http://epydoc.sourceforge.net |