* Throw proper exception in TestJoystick if none found

git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@7440 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
3.0
Sha..om 14 years ago
parent e6d859143f
commit 7d91174b5b
  1. 3
      engine/src/test/jme3test/input/TestJoystick.java

@ -21,6 +21,9 @@ public class TestJoystick extends SimpleApplication implements AnalogListener {
@Override
public void simpleInitApp() {
Joystick[] joysticks = inputManager.getJoysticks();
if (joysticks == null)
throw new IllegalStateException("Cannot find any joysticks!");
for (Joystick joy : joysticks){
System.out.println(joy.toString());
}

Loading…
Cancel
Save