Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Input.is_key_pressed does not work with physical_scancode. #55244

Closed
jitspoe opened this issue Nov 23, 2021 · 1 comment · Fixed by #55251
Closed

Input.is_key_pressed does not work with physical_scancode. #55244

jitspoe opened this issue Nov 23, 2021 · 1 comment · Fixed by #55251

Comments

@jitspoe
Copy link
Contributor

jitspoe commented Nov 23, 2021

Godot version

3.4

System information

Windows 10

Issue description

Due to some other input issues, I've been using Input.is_key_pressed() to check for input, but this doesn't work with the physical scancodes. I need a way to convert physical scancodes to scancodes or a separate is_physical_key_pressed() function.

This is related to this proposal here, though it's a bit more critical, as my game can't currently function with physical scancodes without it: godotengine/godot-proposals#3571

Steps to reproduce

Change your keyboard layout to something non-QWERTY. Call Input.is_key_pressed(<physical scan code of key that's different from QWERTY key>) while the key is pressed and note that the result is false.

@Calinou Calinou added this to the 3.5 milestone Nov 23, 2021
@Calinou
Copy link
Member

Calinou commented Nov 23, 2021

cc @bruvzg

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants