big thank you for your powerful tool.
I'm recently using ff4 ssam script to extract another *.mass archive from NDS game Avalon Code (using JP ver, also developed by Matrix software).
It's also a mixture of plain files and *.lz compressed files, and so far the file decompression is good,
but when I try to reimport, the game just don't recognize it and get crashed.
I did a simple inspect, vanilla header of compressed files (for example .NCGR.lz) starts with
10 B0 04 00 00 then `RGCN`
while reimport header is
40 B0 04 00 00 then `RGCN`
and I also tried:
1. Change the `comtype` to `lz77wii_raw10`, but it simply won't let me extract/import.
2. Change the header bit from `0x40` to `0x10`, same result in crashing the game. Only confirmed the algorithm QuickBMS defaultly used for lz77wii is imcompatible for my case.
3. Using `comtype NTCOMPRESS` (tried to get clue from src) but it just tell me
Error: unsupported compression -1 in reimport mode
4. Using CrystalTile2's embedded lz77 compress to get the file compressed, and directly overwrite to corresponding address of *.mass archive, and it simply works
. (output file also with header bit 0x10) But that would be asspain if I want to do a massive import.
Based on my inspection, I'm here asking for help with:
1. A fix on the lz77wii compression
2. A temporary fix for the script to extract/import untouched/compressed *.lz files (raw out)
Sadly, I have limited ability on coding, and it is a bit complicated for me to understand the bms script. I tried to make a raw output script, but can't just get pass unknown errors.
Can you help me out? Ty in advance. I can send you related files through email.