Class DefaultInputMode

java.lang.Object
com.jme3.app.state.AbstractAppState
jme3utilities.NamedAppState
jme3utilities.SimpleAppState
All Implemented Interfaces:
com.jme3.app.state.AppState, com.jme3.input.controls.ActionListener, com.jme3.input.controls.InputListener

public class DefaultInputMode extends InputMode
The standard initial InputMode for an ActionApplication.
  • Method Details

    • updateBindings

      public void updateBindings()
      Update the bindings to reflect the state of the FlyByCamera, if any.
    • defaultBindings

      protected void defaultBindings()
      Add default hotkey bindings to mimic SimpleApplication. These bindings will be used if no custom bindings are found. They are handled by the ActionApplication class.
      Specified by:
      defaultBindings in class InputMode
    • initialize

      public void initialize(com.jme3.app.state.AppStateManager stateManager, com.jme3.app.Application application)
      Initialize this (disabled) mode prior to its first update.
      Specified by:
      initialize in interface com.jme3.app.state.AppState
      Overrides:
      initialize in class InputMode
      Parameters:
      stateManager - (not null)
      application - (not null)
    • onAction

      public void onAction(String actionString, boolean ongoing, float tpf)
      Process an action from the keyboard or mouse.
      Parameters:
      actionString - textual description of the action (not null)
      ongoing - true if the action is ongoing, otherwise false
      tpf - time interval between frames (in seconds, ≥0)