Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //you'll need: import org.lwjgl.input.Keyboard;
- //also declare boolean toggleKeyPressed in your java file
- if(Keyboard.isKeyDown(Keyboard.KEY_F7)) {
- if(!toggleKeyPressed)
- {
- toggleKeyPressed = true;
- //your code
- }
- } else {
- toggleKeyPressed = false;
- }
Advertisement
Add Comment
Please, Sign In to add comment