Vanilla bugfix, allow fishing with blank B#6826
Open
djevangelia wants to merge 6 commits into
Open
Conversation
Member
|
this should only be enabled by default for rando, a fix should be added to enhancements menu to fix always |
Contributor
Author
|
How do I make a setting enabled by default for certain mode? I guess it would be one setting that can be toggled no matter mode? |
Member
|
|
Contributor
Author
|
Ok, setting for normal, always on for rando. Added enhancement setting. Tested both normal and randomizer. |
serprex
reviewed
Jun 28, 2026
serprex
reviewed
Jun 30, 2026
serprex
approved these changes
Jul 1, 2026
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.
Background
When fishing and other things that change the B button item, the game saves the previous B item
gSaveContext.equips.buttonItems[0]as temp B,gSaveContext.buttonStatus[0]. However, this variable is also used as a flag for whether a button is enabled or disabled (dimmed), which is value0xFF.Normally when fishing, the sword/equip value is not
0xFFand gets saved as temp B so button B is regarded as enabled.Player_ProcessItemButtonssees that current item isITEM_FISHING_POLEwhich is equipped to an enabled button, and lets player continue holding the pole and use it.Blank B is value
0xFF. When starting fishing with blank B,0xFFgets saved as temp B, which will be interpreted as the B button being disabled. This forcesPlayer_ProcessItemButtonsto change player item to none, because the held item is not equipped on a usable button (same system causes item putaway when entering water). Note that this is not dependent on swordless flag, it's only dependent on blank B.Fix
Add check that if fishing and
ITEM_FISHING_POLEis on B, do not unequip. On B press, set buttonitemtoITEM_FISHING_POLEasPlayer_GetItemOnButtondoesn't returngSaveContext.equips.buttonItems[0]but the macroB_BTN_ITEM, which returns0xFFifgSaveContext.buttonStatus[0]is0xFF.I also checked the OoTR fix, and it is the same concept except the stop unequip is done earlier (before
Player_ItemIsInUse) andPlayer_GetItemOnButtonis modified to returnITEM_FISHING_POLE.Demonstration of cause and fix: https://www.youtube.com/watch?v=GFjbs4zS4Cc
(made in decomp for the on-screen data)
Can be tested easily by going into Dev tools and setting player B item to none, gives blank B.
Note
I made this as always on just to submit it for now, so that others can decide what kind of setting it should be and review it.
Build Artifacts