ProdCode : array of AnsiChar įiller : array of byte end Padding8 : integer //always 0x00000000? end ProdCode : array of AnsiChar //20 bytes, 0x00 filled & terminated Padding4 : integer //always 0x00000000?ĭataSize : integer //save size repeated? NumberOfFilesInDir : integer //this is likely to be number of files in dir + 2 ("." and ".")įilename : array of AnsiChar end įilename : array of AnsiChar // 'Real' PSV files have junk in this after text.īlockSize : integer //always 0x00020000 (512). Icon3Pos : integer //position of 3rd icon Icon2Pos : integer //position of 2nd icon
Icon1Pos : integer //position of 1st icon SysPos : integer //location in file of icon.sys SaveType : integer //0x00000002 PS2, 0x00000001 PS1 end ĭisplaySize : integer //PS3 will just round this up to the neaest 1024 boundry so just make it as good as possible Padding := roundUp(clump.Position + 8, 16) - 8 - clump.Position Write (padd, sizeOf (padd ) ) end end end Ĭlump.Write(fileDetails, sizeof(fileDetails)) Ĭlump.CopyFrom(aFile^.data, fileDetails.size) Position for b : = 1 to padding do beginĬlump. Write (fileDetails, sizeof (fileDetails ) ) Ĭlump.
PS2 SAVE TOOLS ARCHIVE
The full code creating the archive in the ARMax DLL is: Padding := roundUp(clump.Position + 8, 16) – 8 – clump.Position The padding following file data is calculated using the following algorithm: The archive is a simple format consisting of file information followed by the actual data and then some padding repeated for as many files as there are: offset Checksum (CRC32 all of file with checksum area treated as 0x00000000Īfter uncompressing the data using the lzAri algorithm you will have an archive file containing the actual files.