Documentation ¶
Index ¶
Constants ¶
View Source
const HeaderExpectedLength = 32
Total size (bytes).
View Source
const UserfileExpectedLength = 524288
Size of full file is always 524288 bytes (extra data are nulls).
Variables ¶
This section is empty.
Functions ¶
func GetDataXMLFromUserfile ¶
GetDataXMLFromUserfile extracts the XML data from a compressed userfile (a .sav that already has a valid header and the compressed data). It skips the header bytes.
Types ¶
type Header ¶
type Header struct { Version uint32 // PC = 21. Size uint32 // Size of the uncompressed data. CompressedSize uint32 // Size of the compressed data. UH1 uint32 // Always 860693325. UH2 uint32 // Always 0. UH3 uint32 // Always 860700740. Checksum uint32 // Checksum of compressed save data (Bitwise not CRC32 Jam). UH4 uint32 // Always 1079398965. }
func NewHeaderFromContents ¶
NewHeader creates a new Header from the contents of a .sav userfile.
func (*Header) Print ¶
func (h *Header) Print()
Print prints the Header structure for log debugging.
Click to show internal directories.
Click to hide internal directories.