bruvzg / gdsdecomp

Godot reverse engineering tools
MIT License
1.42k stars 138 forks source link

When the file name is not in English, e.g. Chinese, Japanese, Korean, it will be garbled. #73

Closed Yakumo-Yukari closed 1 year ago

Yakumo-Yukari commented 1 year ago

test Is there any solution to this problem?

nikitalita commented 1 year ago

Hmmm, it's either that we don't have east asian character support in the font that we use with GDRE Tools, or the file names were not UTF-8 encoded. When extracting, are the file names rendered correctly or are they still garbled?

Yakumo-Yukari commented 1 year ago

Hmmm, it's either that we don't have east asian character support in the font that we use with GDRE Tools, or the file names were not UTF-8 encoded. When extracting, are the file names rendered correctly or are they still garbled?

Files can be displayed correctly after being extracted to a folder

nikitalita commented 1 year ago

Ah, then it's likely just a font issue. Can you recommend a good open source font that has good support for both Latin characters as well as East Asian characters?

Yakumo-Yukari commented 1 year ago

Ah, then it's likely just a font issue. Can you recommend a good open source font that has good support for both Latin characters as well as East Asian characters?

I'm very sorry, I don't have a better font to recommend either

nikitalita commented 1 year ago

That's ok, I found this: https://fonts.google.com/noto/specimen/Noto+Sans/about

Can you supply a sample game that has chinese character names in the files so that I can test his?

nikitalita commented 1 year ago

Well, the good news is that including this font does fix the issue; the bad is that it's 33mb in size, it's not really an option to include it.

However, it should just be falling back to the system fonts if it's not able to render a character correctly. @bruvzg , do you know why it wouldn't be using a fallback font here, or do we have to configure those manually? If they have to be configured manually, how would we do that per platform?

nikitalita commented 1 year ago

Ok, they apparently have to be configured manually. I’ll whip up a quick hack later today.

nikitalita commented 1 year ago

When the CI finishes building, can you download one of the "standalone" artifacts here and see if this fixes your issue? https://github.com/bruvzg/gdsdecomp/actions/runs/3232103113

nikitalita commented 1 year ago

Also, let me know what OS you're on (Linux, Windows, etc.)

Yakumo-Yukari commented 1 year ago

Also, let me know what OS you're on (Linux, Windows, etc.)

Windows 10

nikitalita commented 1 year ago

Did the standalone windows artifact work for you?

Yakumo-Yukari commented 1 year ago

Did the standalone windows artifact work for you?

Yes, it fits perfectly, now it's just so cool

nikitalita commented 1 year ago

Excellent, I shall merge the PR and tag a new release then.