Extend space available for message data #1837
Merged
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.
Use both the Japanese and English message files for storing messages. The JP file is written to first, followed by the EN file, for a total space of 0x74000 bytes (up from 0x39000 bytes). Which file to load is determined by the segment number for a given text ID in the message table. 0x08 will load JP, 0x07 will load EN. More info on the message table format is at https://wiki.cloudmodding.com/oot/Text_Format.
Message 0xFFFC in the JP table is used by the title and file select screens with hard-coded offsets based on the vanilla JP file. This is accounted for at patch time by updating the hard-coded values to the new location in whichever file the message is placed.
Text shuffle appears to still work based on a quick test.
Testing the file split needs to either artificially decrease the JP text file size or add a lot more text to the game. Message relocation to the JP file works fine, so this should be OK but is untested as of submission. I'll take a look when I have more time to hunt for specific text in-game.