예제 #1
0
  private void onKeyEventQueued(KeyInputEvent evt) {
    if (evt.isRepeating()) {
      return; // repeat events not used for bindings
    }

    int hash = KeyTrigger.keyHash(evt.getKeyCode());
    invokeActions(hash, evt.isPressed());
    invokeTimedActions(hash, evt.getTime(), evt.isPressed());
  }
예제 #2
0
  private void onJoyButtonEventQueued(JoyButtonEvent evt) {
    //        for (int i = 0; i < rawListeners.size(); i++){
    //            rawListeners.get(i).onJoyButtonEvent(evt);
    //        }

    int hash = JoyButtonTrigger.joyButtonHash(evt.getJoyIndex(), evt.getButtonIndex());
    invokeActions(hash, evt.isPressed());
    invokeTimedActions(hash, evt.getTime(), evt.isPressed());
  }
예제 #3
0
 private void onMouseButtonEventQueued(MouseButtonEvent evt) {
   int hash = MouseButtonTrigger.mouseButtonHash(evt.getButtonIndex());
   invokeActions(hash, evt.isPressed());
   invokeTimedActions(hash, evt.getTime(), evt.isPressed());
 }