Close inventory menus by pressing E#746
Closed
DanilochTop wants to merge 2 commits intosmartcmd:mainfrom
Closed
Conversation
|
W |
Collaborator
|
Unsure if this is a good solution for maintaining existing functionality on controller considering this isn't a KBM specific action |
Author
|
I see. I also thought about this, but I was unsure if the |
Collaborator
|
Fixed via different strategy in an earlier PR |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
This PR introduces the feature to close inventory menus (such as inventory, crafting, furnace, etc) by pressing E.
Changes
Previous Behavior
Most inventory menus didn't respond to the E key press, except for crafting menus, which used this key to scroll through options.
Root Cause
Design flaw.
New Behavior
All inventory menus now respond to the E key press, allowing player to close them by doing such. The crafting inventory and other ones that use it for scrolling have their functionality intact.
Fix Implementation
I just added a check for the
ACTION_MENU_RIGHT_SCROLLenum value on the switch case in functionhandleKeyDownfrom classIUIScene_AbstractContainerMenu.cpp.AI Use Disclosure
AI was used solely to find the code responsible for that.
Related Issues