So I'm not 100% sure what you would call this type of keypress, but it is essentially a keyTyped
event but in reverse order. Instead of being triggered when the button is released, it is triggered when the button is first pressed, but can't be triggered again until the button is released and pressed again.
Right now I have events for buttonDown
and buttonUp
and I also have two HashMap
s to keep track of the currentInput
and previousInput
of each action in the game (jumping, moving, crouching, etc...) How can I provide a function that when called returns true for this type of button push?