three-houses-research-team / THAT

THAT - Three Houses Archive Tool
GNU General Public License v3.0
3 stars 3 forks source link

g1t.gz error after compress. #1

Closed JokerDKha closed 2 years ago

JokerDKha commented 2 years ago

Sorry for bother you, but i need help about this g1t.gz. After decompress and edited file font picture, i try to compress it back to gz but it make a games freeze. Sample file on Patch 4: font00_JPN.g1t.gz

VelouriasMoon commented 2 years ago

Could you walk me through your process? there's many steps along the way that can cause this including how you're trying to load the file in game.

JokerDKha commented 2 years ago

Step 1: I decompress g1t.gz to g1t Step 2: I extract g1t to png with a G1Tool Step 3: After edit png file, im use G1Tool to Replace new .dds DXT5 to g1t Step 4: I using THAT to compress g1t to gz again.

I also try decompress and compress file not edit anything, but it still not working. im using info path like patch 4 file: 010055D009F78000\romfs\patch4\nx\ui\font

JokerDKha commented 2 years ago

Update: i know what wrong with this file after compressing. Original file have: some hex below a like this image In new file compress i copy that hex like original image and the game is working normal: image Now i will edit picture again and compress it one more time, i will update soon if have any error.

VelouriasMoon commented 2 years ago

hmm, interesting find, guess it wouldn't be a Koei Tecmo game without useless padding that makes the game crash without it. I'll have look into if there's any reason it exist.

VelouriasMoon commented 2 years ago

Issue was with the compression aligning the entries to 128 but not the end of the file, thus causes the issue of the missing bytes.

JokerDKha commented 2 years ago

Now i want mod this file. but File Found with no ID: rom:mods/nx/ui/font/72.bin.gz What can i do now to mods this file? this file location in data0.bin image @VelouriasMoon image