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

Block bound inventory keys from auto assignment #40288

Merged
merged 5 commits into from
May 8, 2020

Conversation

eJ0opb
Copy link
Contributor

@eJ0opb eJ0opb commented May 7, 2020

Summary

SUMMARY: Interface "Block bound inventory keys from auto assignment"

Purpose of change

It is very annoying when auto inventory letter assignment assigns over your preferred navigation keys.

Describe the solution

Check if the letter is bound to an inventory action before automatically assigning it.

Describe alternatives you've considered

  • Turning off auto inventory letters
  • Limiting myself to 7 favorites
  • Buying a keyboard with arrow keys

Testing

  1. Set auto inventory letters to enabled (favorites does not currently work in a way that I understand)
  2. Create a character with more than 7 starting items
  3. Observe that your navigation keys are not assigned
  4. Manually assign your navigation keys.
  5. Navigation keys select their assigned items instead of navigating

Additional context

Favorites and auto inventory letters seem to currently be in a bad state, so testing is limited.

Changing your key bindings after the letters have already been assigned doesn't work well. I managed to finagle it into doing the right thing by manually unassigning everything, stripping naked, and picking everything back up again.

@Lamandus
Copy link
Contributor

Lamandus commented May 7, 2020

will that also happen if you don't have hjkl assigned? Maybe it should be linked to the buttons you have for movement. Some prefer even WASD

@ymber
Copy link
Member

ymber commented May 7, 2020

This should block any keys currently bound to menu navigation.

@enaantd
Copy link
Contributor

enaantd commented May 7, 2020

Maybe it should be linked to the buttons you have for movement. Some prefer even WASD

agreed, or even custom movement keys for those with an exotic keyboard layout (in my case I move with u-p-e-x). it would be a shame to hardcode this feature

@eJ0opb
Copy link
Contributor Author

eJ0opb commented May 7, 2020

Who has familiarity with the inventory input code? I looked at it, and I could not figure out how to find the relevant keybindings in a reasonable amount of time.

@mlangsdorf mlangsdorf added the Info / User Interface Game - player communication, menus, etc. label May 7, 2020
@eJ0opb eJ0opb force-pushed the auto-inventory-no-vi-keys branch from 83e331c to ab9a024 Compare May 8, 2020 00:24
This is almost certainly the wrong way; someone more qualified
really ought to look at this.
@eJ0opb eJ0opb force-pushed the auto-inventory-no-vi-keys branch from ab9a024 to 90140e6 Compare May 8, 2020 00:24
Co-authored-by: anothersimulacrum <anothersimulacrum@gmail.com>
@eJ0opb eJ0opb changed the title Remove hjkl from auto inventory letters Block bound inventory keys from auto assignment May 8, 2020
src/inventory.cpp Outdated Show resolved Hide resolved
Co-authored-by: Curtis Merrill <curtis.r.merrill@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Info / User Interface Game - player communication, menus, etc.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants