I guess I'm not sure if this applies to Wii games in general, but I recently decided to hunt for some files in Pokemon Battle Revolution and noticed that most of the interesting files are LZSS compressed. After some searching I found a tool called gbalzss which has apparently been successful in decompressing certain wii files in addition to GBA files. I tried it out on several of the files I had extracted with no luck; it was pretty apparent by looking at the output files that they were not decompressed properly. I did make sure to chop off the "LZSS" that was tacked onto the beginning of each file before doing this.
A couple observations:
-In traditional GBA/NDS/Wii compressed files there is a 4-byte header, the first byte of which specifies a compression method and the last 3 which give an decompressed filesize. The header is apparent here, but it is preceded by the identifier LZSS and it has a couple twists.
-The compression method byte is left blank, but that isn't a major issue because we already know it is LZSS.
-I am 99% sure the decompressed filesize is in big endian. As far as I can tell everything else, wii archive files included, are little endian.
Download a sample file here.
Does anybody have any insights on why gbalzss will not decompress these files correctly? Is anybody willing to do some debugging to figure out how wii games do it?
EDIT: To clarify, I have already tried standard LZSS decompression as well as Nintendo's LZ77 (both variants), RL, and Huffman with no success.
A couple observations:
-In traditional GBA/NDS/Wii compressed files there is a 4-byte header, the first byte of which specifies a compression method and the last 3 which give an decompressed filesize. The header is apparent here, but it is preceded by the identifier LZSS and it has a couple twists.
-The compression method byte is left blank, but that isn't a major issue because we already know it is LZSS.
-I am 99% sure the decompressed filesize is in big endian. As far as I can tell everything else, wii archive files included, are little endian.
Download a sample file here.
Does anybody have any insights on why gbalzss will not decompress these files correctly? Is anybody willing to do some debugging to figure out how wii games do it?
EDIT: To clarify, I have already tried standard LZSS decompression as well as Nintendo's LZ77 (both variants), RL, and Huffman with no success.