bsabiston
Member
I doubt anyone will have an answer for this, but ...
I'm trying to detect the SHIFT key being held down at the time I launch my game - I want it to start up in a different configuration in that case.
var shiftKey = keyboard_check(vk_shift)
But, on MacOS at least, the keyboard_check commands don't work at that time.
Maybe because the window has not been created yet or received focus? I'm not sure. Although the window is there on screen and looks to have focus when I do my check.
The keyboard and mouse commands work at other times, so it seems to have something to do with the game first starting?
I also tried keyboard_check_direct and that returned "undefined"
I also tried testing the mouse instead:
var mouseDown = mouse_check_button_pressed(mb_left)
but that also does not correctly detect the mouse held down.
Anyone know how to do it or some other alternative?
I'm trying to detect the SHIFT key being held down at the time I launch my game - I want it to start up in a different configuration in that case.
var shiftKey = keyboard_check(vk_shift)
But, on MacOS at least, the keyboard_check commands don't work at that time.
Maybe because the window has not been created yet or received focus? I'm not sure. Although the window is there on screen and looks to have focus when I do my check.
The keyboard and mouse commands work at other times, so it seems to have something to do with the game first starting?
I also tried keyboard_check_direct and that returned "undefined"
I also tried testing the mouse instead:
var mouseDown = mouse_check_button_pressed(mb_left)
but that also does not correctly detect the mouse held down.
Anyone know how to do it or some other alternative?
Last edited: