Lunadata.fil filing system format, as found on the lunadata.fil file, located on the lunar sssc cds.
First 32 bytes - Header
offset len purpose
0x00 1 equals 0x2E, purpose unknown.
0x01 19 equals 0x00, possibly reserved area.
0x14 4 Number of Files (numfiles)
0x18 4 Length of this data file
0x1C 4 unknown area, possibly reserved.
Next numfiles*32 bytes
for each file entry
0x00 20 File name
0x14 4 image cluster number where file is, each cluster is 0x800 bytes.
if even 1 byte of the cluster is used, the remaining 0x7FF bytes
is wasted.
0x18 4 Actual length of file
0x1C 4 purpose unknown
Just like a hard drive, the file is arranged into clusters.
Now that I know the filing system, I can write a program to extract all of the game data from the image file,
including the SEQ/VAB data.
Format of *.snd files
Do until EOF
Skip 4 bytes
Read next 4 bytes, to determine length of data
Read next len bytes.
Loop.
Files are arranged in this order
Vab Header
Vab Body
SEQ data
end of *.snd files