I'm making an application using lwjgl and I'm having troubles with toggling using the same key. What I want is for the boolean to be toggled when I release the key. I have a method that returns the toggle state and checks for any changes at the same time, but this is proving kind of difficult and overly complex. Is there any way I can make this easier? If not, could someone tell me how to go about toggling with the same key?
Any help is appreciated, thanks in advance!