keyboard

  1. B

    keyboard_key_press(key) and keyboard_check_pressed(key)

    Hi, I'm trying to write some unit tests and need to simulate a key being pressed for an object's keyboard_check_pressed event to be true. I was under the impression keyboard_key_press(key) would simulate that the key was being pressed, thus making keyboard_check_pressed(key) return true, but...
  2. Jihl

    GMS 2 Issue with keyboard check

    Hey there guuysss... Somehow my game manages to get spikes on the keyboard input but not in the actual FPS of the game, that makes my game sometimes miss a keypress and when you are chatting it is very uncomfortable. I have used the debugger to ensure it is not an FPS drop when a key is...
  3. Shadowblitz16

    GMS 2 get current key pressed?

    is there a way to get the currently pressed keyboard key by looping through keys? something similar to what this does for the gamepad.. for ( var i = gp_face1; i < gp_axisrv; i++ ) { if ( gamepad_button_check( 0, i ) ) return i; } return false; I don't want to use keyboard_lastkey...
  4. Dioramos

    Custom keyboard binding

    In settings i want to make all my in-game buttons, so the player can choose the button he needs and set it to new button. How to make a check what button the player pressed? And how to set this button to all other systems? Sorry for bad english, thanks
  5. J

    Why does my player get stuck in the air?

    Im making a platform game where my character can duck. When he ducks in the air, he performs a groundpound. key_duck is asigned to the 'S' key (not pressed or released). vsp is the vertical speed and duckgrav is the groundpound speed. While performing the groundpound, the sprite should be...
  6. Patrick Johnson

    GML Tapping Keys without Holding [SOLVED]

    Hey all, I need some help with keyboard tapping. What I want to do: Quickly Tap the space key on a keyboard to launch the start menu Quickly Tap the space key on a keyboard again to close the start menu What I have figured out already: How to execute/stop the script itself What I have tried...
  7. K

    GMS 2 problem with keyboard_check, keyboard_check_pressed and keyboard_check_released

    Hello: Firstly I thank everyone for any support you guys could provide, I've been working with GMS 2 for a while now and It has been awesome so far. but right now I am a bit confused, I have the following code: if keyboard_check(ord("X")) { state = STATE.CHARGING; } else if...
  8. NNNIKKI

    GMS 2 Punctuation keyboard_check

    How can I use keyboard_check, _pressed and _released with punctuation symbols, such as , . / ; ' [ ] - = ..? In the manual, it said to use "keyboard_lastchar", but I think that'll only work with pushing the button, and I also want to register when you release that button. How do I do this?
  9. BitRoarGames

    GMS 2 Get String in Console Exports

    Version: Game Maker Studio 2 Full - IDE v2.2.1.375 - Runtime v2.2.1.291 So I've been working on a game that I'd like to be more console friendly for future exports and have no idea how getting a user entered string would work on something like PS4 and Nintendo Switch. Since my main target...
  10. Edwin

    GML keyboard_check_pressed(vk_windows)

    Hello, people. How I can check if player pressed Windows key? I want to pause game if player pressed it, but there is no such vk_ constant in manual. By the way, my GM:S version is 1.4.9999.
  11. 1

    GMS 2 Can’t Make Keyboard Binding Menu

    im having trouble creating s options menu for gsm 2 where the player can customize controls by typing in his/her own key for a movement. There seems to be no tutorials on how to do this. Ex. I know it’s fortnite, but I want the customizabilty of the keybinds in my game Please help!
  12. Bladevampirek

    Accept Input for ".';/,[]\=-` Tab CapsLock Shift" & More?

    I'm making a virtual keyboard, this will be used to make learning Touch Typing Easier for people, Game Maker cannot recognize the keys that I underlined with red in the photo above. Is there a way to make it recognize any of these key inputs, so that I can change sprites when the key is pressed...
  13. Bladevampirek

    I want to make a virtual onscreen keyboard using Game Maker Studio.

    I want to make a Keyboard program for Windows in which a user can open on their screen, then type, and the keystrokes they press will light up. I know how to do this, but I don't know how to make it work in the background while the user is typing in their browser or on Notepad.exe, any...
  14. Alivesoft

    keyboard_lastkey problem in HTML5

    keyboard_lastkey in HTML5 is not working properly in v1.4.9999, It does not record single key presses, you need to press and hold for a couple of seconds to respond. It works fine in native WIndows. To see the problem, insert the following in a simple object's step event (and compile under...
  15. Dr_Nomz

    GML keyboard_check(vk_space) doesn't work? (instance_change)

    So I put this in the step event of my character... if keyboard_check(vk_space){ instance_change(obj_Character_ROLL,true); } But it wouldn't work. It works fine if I just put the middle bit of that code into the "spacebar" event, but why doesn't it do anything like this? EDIT: Is it a...
  16. B

    Linux Cannot press control + arrow keys

    Hello! I'm experimenting with a Linux build and everything is working fine. Just one question: Has anyone encountered and have any experience with the fact that Linux os doesn't seem to allow pressing and holding the control button at the same with arrow keys? Is this built into the os? I'm...
  17. B

    Linux Keyboard controls don't work in Linux build

    Linux users playing my game DASH can't press two buttons at the same time? It's a platformer (so you press several keys at the same time all the time) and there is no way I am redesigning the controls and mechanics because of this. All my keyboard check code is simply standard gml. Nothing...
  18. jobjorgos

    Legacy GM is keyboard_check an equal event to gamepad_axis_value?

    Heya. In my game I had the following script for the movement of the player which worked fine: left = keyboard_check(vk_left) or keyboard_check(ord('A')); right = keyboard_check(vk_right) or keyboard_check(ord('D')); up = keyboard_check(vk_up) or keyboard_check(ord('W')); down...
  19. Gravedust

    Windows Lancerbird - A Joust Fangame

    Lancerbird is a free, Joust-inspired game where you flap around on giant birds and try to dismount enemies (and/or one another). I started it as a Christmas present for a Joust-fan in my life and I've slowly been improving it since. It's not really meant to be a faithful recreation; Quite a few...
  20. ltzibaozhe

    GMS 2 How to skip keyboard events when using mouse and keyboard ?

    Hello! I just started learning GML. I made an 8-direction player. 01 Keyboard WASD controls walking and has 8 correct sprite direction. When you click the mouse, it jumps a certain distance sprite the direction of the mouse and has the correct sprite direction. 02 problem is...
Top