AtomCrafty / yukatool2

New and fresh version of yukatool, rewritten from the ground up to be much faster and more maintainable than its predecessor
GNU General Public License v3.0
13 stars 1 forks source link

Filename case is not preserved on unpack. #5

Closed Andrei-Stakov closed 3 years ago

Andrei-Stakov commented 3 years ago

Found this issue while searching clues for #4 .

With a repackaged .ykc from the original with no modified files, the game engine refuses to use the contained files and popups a missing file warning. Noticed that the path shown in the popup was having uppercase filename, I tried to batch-converted all related files (that were considered as missing by the engine) to uppercase, packit up again, and now it runs perfectly.

This might be a combination of few possible points:

I've experimented with a simple directory with various cased files and folders, and it was clear that unpack isn't properly preserving the filename case, as in this screenshot: image

I'll include the sample directory case (with various cased filenames) for easier analysis. test.zip

Here's the tree-list for the packed .ykc of the sample case, seen through YukaTool GUI: image

AtomCrafty commented 3 years ago

The file name normalization was an intentional design choice, because I was fed up with the inconsistent naming used by some devs. I'm surprised this is causing any issues, the engine version I worked with accepted the lowercase files just fine.

Anyway, in release 2.5 I added the command line option --normalize-case=false to disable the normalization.
And while I was at it I also created a list command so you don't have to check with YukaTool GUI every time ^^

image

Andrei-Stakov commented 3 years ago

Thank you for the awesome help 😄 ! This would surely saves me a lot of headache.

Yeah, it's a surprise for me too, since normally they wouldn't want to tire themselves out regarding filename case in a complex game like this. I hope that this is just particularly specific to this game only, and not spread out to the rest of PeasSoft's other games.

Again, thank you very much for such a swift responses and assistance!