-
-
Notifications
You must be signed in to change notification settings - Fork 493
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
Inconsistent confirmation keys #1400
Comments
I started to look at this. I'm not familiar with the code, so it's gonna take some time. After some debugging I found out that on my machine following default mappings from @Narre if you have keyboard with a keypad can you please confirm that keypad Enter works for you in worldmap and level intro? m_keymap[SDLK_RETURN] = Control::MENU_SELECT;
m_keymap[SDLK_KP_ENTER] = Control::MENU_SELECT; It looks that when Worldmap/Level intro processes the keys (through auto key_mapping = m_keyboard_config.m_keymap.find(event.keysym.sym); Then it goes to else if (key_mapping == m_keyboard_config.m_keymap.end())
{
// default action: update controls
//log_debug << "Key " << event.key.SDL_Keycode.sym << " is unbound" << std::endl;
} And is effectively ignored. |
I also looked to the config file and noticed that I have this weird KP_RETURN entry. Removing it also solves the problem. I wonder from where it came. I've neither modified config file nor keyboard settings in the game, ever.
But I remember that I switched keyboard some time ago to one with keypad. Maybe it stopped to work back then. |
@szborows I can confirm. Keypad Enter works fine (I honestly haven't even thought of trying that before). |
Ok, I think I know reproduction steps (below). Interestingly, once you cause this issue to happen it will remain.
I know my posts are a little bit "spamish", but I have limited time so I just want to report my findings in case I stop working on this. I'll try to dive deeper soon, though. |
I tried it. You don't need to plug/unplug anything, just turn on/off NumLock and the outcome is the same! I just thought this was changed in SuperTux code, it never occurred to me it was broken THIS MUCH! |
BTW I've got a laptop with a keypad. |
Good catch! |
I only started having this problem somewhere between 0.5.1 and 0.6.0, it worked fine before that. |
Possibly related issue: #1282 |
@HybridDog @christ2go @tobbi FYI (sorry for spam) |
SuperTux 0.6.2
Ubuntu 20.04
To confirm a selection (whether it's a menu item or a level in a worldmap), the player has to press either Enter, Space, Ctrl(or Alt, or whatever ACTION is bound to), or use the mouse (where applicable). However, this is very inconsistent. For example, in the main menu, any of the options can be used, when selecting a level in a worldmap, Enter doesn't work, in certain menus in the editor, Space doesn't work, in the 'Do you want to save' menu, both Enter and Space don't work, etc.
I've also noticed that 'P' can no longer be used instead of Escape (for Pause / skip dying animation). That can get really annoying - I still keep pressing P even though it hasn't worked for a while.
I'm not sure if this was changed intentionally or not, but at least the inconsistencies should be sorted out. Maybe 'Confirm' and 'Pause' could even be settable in Options. Or at the very least, all the keys that can be used as 'Confirm' somewhere should be able to be used as 'Confirm' anywhere.
The text was updated successfully, but these errors were encountered: