gzz.client
Class JoystickState
java.lang.Object
|
+--gzz.client.JoystickState
- All Implemented Interfaces:
- JoystickListener
- public class JoystickState
- extends java.lang.Object
- implements JoystickListener
The current state of a joystick.
Method Summary |
void |
axis(long ms,
int axis,
float value)
An axis was moved. |
void |
button(long ms,
int button,
boolean value)
|
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
timestamp
public int timestamp
time
public long time
axes
public float[] axes
- The current axis values, normalized to -1..1.
buttons
public boolean[] buttons
JoystickState
public JoystickState()
toString
public java.lang.String toString()
- Overrides:
toString
in class java.lang.Object
axis
public void axis(long ms,
int axis,
float value)
- Description copied from interface:
JoystickListener
- An axis was moved.
- Specified by:
axis
in interface JoystickListener
- Parameters:
ms
- The timestamp of the event, in milliseconds
compatible with System.currentTimeMillis().
button
public void button(long ms,
int button,
boolean value)
- Specified by:
button
in interface JoystickListener