Permalink
Browse files

Allow the caller to override the axis' default dead

zone configured at startup.
  • Loading branch information...
1 parent 2a2c71d commit 46794e251d240252ebddc75a88215b942f6a9804 @pspeed42 pspeed42 committed Dec 5, 2015
Showing with 8 additions and 0 deletions.
  1. +8 −0 jme3-core/src/main/java/com/jme3/input/DefaultJoystickAxis.java
@@ -135,6 +135,14 @@ public float getDeadZone() {
return deadZone;
}
+ /**
+ * Sets/overrides the dead zone for this axis. This indicates that values
+ * within +/- deadZone should be ignored.
+ */
+ public void setDeadZone( float f ) {
+ this.deadZone = f;
+ }
+
@Override
public String toString(){
return "JoystickAxis[name=" + name + ", parent=" + parent.getName() + ", id=" + axisIndex

0 comments on commit 46794e2

Please sign in to comment.