MCPcopy Create free account
hub / github.com/diasurgical/devilution / InitDefaultMpqHeader

Function InitDefaultMpqHeader

Source/mpqapi.cpp:284–293  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

282}
283
284void InitDefaultMpqHeader(Archive *archive, _FILEHEADER *hdr)
285{
286 std::memset(hdr, 0, sizeof(*hdr));
287 hdr->signature = '\x1AQPM';
288 hdr->headersize = 32;
289 hdr->sectorsizeid = 3;
290 hdr->version = 0;
291 archive->size = kMpqHashEntryOffset + kHashEntrySize;
292 archive->modified = true;
293}
294
295bool IsValidMPQHeader(const Archive &archive, _FILEHEADER *hdr)
296{

Callers 2

ReadMPQHeaderFunction · 0.85
OpenMPQFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected