Talk:SARC (File Format)

From MK8
Revision as of 16:34, 12 September 2014 by Parax0 (Talk | contribs)

Jump to: navigation, search

Node Hash

I'm pretty sure that the value at offset 0x00 in the node structure is a hash of the filename or an ID, because I have found a stripped archive; one in which the SFNT table is empty. The only plausible way to index the files would therefore be to use this value, the values being sorted supports this hypothesis. Chadderz (talk) 06:12, 20 August 2014 (UTC)

That makes much more sense than my "percentage" theory. Then the files would be sorted by this hash. --Celcodioc (talk) 18:35, 20 August 2014 (UTC)
Yup. Just checked it by comparing 2 different archives that contain an identical file. Definitely a hash, sorry for entering the wrong info. --Celcodioc (talk) 18:41, 20 August 2014 (UTC)
Ah good, nice to have some sort of proof. Don't worry, better to submit a theory that leads to the correct answer than to do nothing :)
Chadderz (talk) 06:00, 21 August 2014 (UTC)
Yea, I also thought that. This format is used in mk7 aswell, and there are no filenames in the file name table. In the ram there are paths to files (with subdirs), so this got to be a hash. --Gericom (talk) 08:57, 24 August 2014 (UTC)

SFAT node filenames

Hi, I just wanted to let you guys know about something I've found. I'm currently exploring A Link Between World's files, and it has a number of Yaz0-compressed SARC archives. What's interesting is that for the most part, the filename table is completely missing on the compressed archives. In addition, on those files the "unknown" 8-bit value at 0x4 in the node structure is set to 0 instead of 1. So it seems to me that that value indicates whether or not the given node has a filename at all. I'm also gonna hazard a guess and say that the unknown 16-bit value at 0x6 in the SFNT header is just padding, considering all the strings are padded to multiple-of-4 offsets and the header would be 6 bytes without it.

Really useful page, thanks for all the work. --Parax0 (talk) 16:23, 12 September 2014 (UTC)

Probably should have read this page a little closer, I see you guys have already run into a bunch of archives with empty SFNT tables. :P Ah well. --Parax0 (talk) 16:34, 12 September 2014 (UTC)