if (_useBufferedKeyboard) {
if (_useBufferedKeyboard && keyboard!=null) {
    public void update(float time) {        if (keyboard != null) {            // added this to keep the polling from being done            // unless we want to do the bufferedKeyboard events.            // don't need the update when doing poll based            if (_useBufferedKeyboard)                keyboard.update();            for (int i = 0; i < keyActions.size(); i++) {                if (keyboard.isValidCommand(((AbstractInputAction) keyActions.get(i)).getKey(),                        ((AbstractInputAction) keyActions.get(i)).allowsRepeats())) {                    ((AbstractInputAction) keyActions.get(i)).performAction(time);                }            }        }        if (_useBufferedKeyboard) {            while (keyboard.getKeyInput().next()) {                boolean keyPressed = keyboard.getKeyInput().state();                if (keyPressed) {                    for (int i = 0; i < buffKeyActions.size(); i++) {                        ((AbstractInputAction) buffKeyActions.get(i)).setKey(keyboard.getKeyInput()                                .getKeyName(keyboard.getKeyInput().key()));                        ((AbstractInputAction) buffKeyActions.get(i)).performAction(time);                    }                }            }        }        if (mouse != null) {            mouse.update();            for (int i = 0; i < mouseActions.size(); i++) {                ((MouseInputAction) mouseActions.get(i)).performAction(time);            }        }    }