Yesterday I encountered a very bizarre problem with UserInputService, Where you can’t press the X key while either A and S, or D and S are both being held.
Any other key apart from X specifically, can still be pressed while these keys are being held down.
I tried switching my keyboard and I tried switching the computer, but the issue persists, so it is not a hardware problem.
This has left an un-fixable bug in my dodging system.
Can you share your implementation of user input service, and method for detecting the faulting input keys?
I’ve had similar issue with the F keys and I’ve usually found the issue is down to my implementation of it.
I tested the problem by printing the inputs, and i found that the X input would not apear in the output as long as A and S or D and S were being held.
The code for the input events:
The function X_Input simply checks which of the WASD keys are being held and then it makes the player dodge in the specified direction.
I tried making this system just print the inputs without the dodging system and the result was the same, so the dodging system is not the cause.
I just did some testing, and C is also affected by this.
There could other keys with the same problem.
This is likely due to the way that UserInputService
handles input. Perhaps use ContextActionService
and see if it still happens, it also has mobile support for input if that’s something you’d like too.
Thanks for the help, this problem may need to be fixed by Roblox as it is likely a bug.