Three keys pressed in demo project 2d/platformer_dcc

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By Enant
:warning: Old Version Published before Godot 3 was released.

I wanted to make a 2d platformer so I decide to take a look at the themo project 2d/platformer_dcc, but when I run it I found a behaviour I don’t quite get:

If you press i.e left + up to jump left and keep them pressed, and then spacebar to try to shoot, nothing happens. The same happens for any same combination of left / up / down / spacebar, but if one of the keys is right, everything works as expected.

Is it supposed to work like that? And how can I avoid it?

Limitation of your hardware or your code. Paste your code handling that ?

Omicron | 2017-03-20 20:16

There’s no “my” code, it’s just the demo project as it is.

https://github.com/godotengine/godot-demo-projects/tree/master/2d/platformer_dcc

Enant | 2017-03-20 20:20

There’s nothing wrong with the code, it works just fine when I tested it. The player shoots when the 2+ direction keys are held and space is pressed. It seems like your OS/hardware may be limiting the input processing to only 2 keys.

It runs fine on Win7/10. What’s your OS/hardware?

gonzo191 | 2017-03-21 01:12

Desktop is W10, AMD FX-6300, M5A9 EVO R2.0 and AMD Radeon R9 200 Series.

I tried also in a Thinkpad 13 with W10an also had the same problem, but just with left-up-spacebar.

I guess it is a HW problem that can’t be prevented?

Enant | 2017-03-21 18:15

This is a serious limitations, try to update your OS… who knows…

Omicron | 2017-03-21 18:32

Hardware limitation may be on the keyboard itself.

You can add more keys to your actions until you find some combination that works, or get another keyboard…

eons | 2017-03-21 20:51

:bust_in_silhouette: Reply From: raymoo

It’s an issue with your keyboard. Cheaper keyboards have keys share some wires, so to prevent accidentally activating an unpressed key by pressing a combination of other keys (ghosting), it just disables conflicting combinations.