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

Fixing the Main Font. #2

Open
Notaloop763 opened this issue Jul 14, 2022 · 2 comments
Open

Fixing the Main Font. #2

Notaloop763 opened this issue Jul 14, 2022 · 2 comments

Comments

@Notaloop763
Copy link

Notaloop763 commented Jul 14, 2022

Hi! I wanted to offer a workaround/Solution for the main Font. This specific solution only works for English, though something similar may work for other languages. The main font actually needs 2 files to be replaced.

  1. Change the name of the file to not use a wildcard. Specifically use the name tex1_256x256_95d10115661a5011_243e7c660b59e2ee_8
  2. When you load into your save file, open the in-game keyboard (Y) and cycle to the 2nd page (R). This will setup your texture atlas to a hash that matches the custom font, and it'll load in.
  3. To fix the arrow and x, you need a 2nd file with a hash of tex1_256x256_5710f581869b5064_243e7c660b59e2ee_8. Scroll through your inventory and go past a weapon/armor, and a stacked inventory item. That'll setup the 2nd hash.

Separate issue, but your main font is missing some characters which is causing missing chacters (like the & symbol). I'm attaching the Dolphin dump of the files with these hashes.

The reason this works is kinda convoluted, but I can explain if there's interest.

Main English Font.zip

@eleriaqueen
Copy link
Owner

Oh wow ! This is very good news ! Thank you.

I'd be interested in an explanation why this works if it doesn't take up too much of your time to write it.

@Notaloop763
Copy link
Author

Notaloop763 commented Jul 14, 2022

The in-memory address at 243e7c660b59e2ee is a dynamic texture atlas. The game will load the characters as-needed to render text on screen to this location. There's also double buffering (aka two pages) at that address. So the game will use page 1 until its full and then it starts using page 2. By wildcarding the hash, you flatten the two pages into one, so that is part of what causes the characters to display wrong. The x is were the apostrophe is, and the arrow around the "g" or "W" location.

The strategy of the workaround is that by displaying your full keyboard immediately, you seed page 1 of the atlas with all the english characters. (The blank spots on the 2nd keyboard grid seem to take up spots in the atlas). It consistently generates the 95d... hash value when page 1 is full. By displaying your inventory next, you start page 2, and seed it with the arrow and x. For the most part, you won't run into new letters so your two atlas pages will remain static. I've played for hours with this workaround in place.

This method also has a good failsafe: If your texture atlas changes after you've set them up then the font reverts to the fuzzy font, it doesn't start rendering letters in the wrong spot like the wildcard would do. The two specific ways it'll break is if someone displays a special character, thus changing your atlas, or if you check out guild cards with special characters. Its fairly easy to reset the game between quests and reset the atlas in that case, or just keep playing with the fuzzy font.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants