MCPcopy Create free account
hub / github.com/TheForceEngine/TheForceEngine / create

Method create

TheForceEngine/TFE_Archive/lfdArchive.cpp:13–30  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

11}
12
13bool LfdArchive::create(const char *archivePath)
14{
15 m_archiveOpen = m_file.open(archivePath, Stream::MODE_WRITE);
16 m_curFile = -1;
17 m_fileOffset = 0;
18 if (!m_archiveOpen) { return false; }
19
20 // Write the directory.
21 LFD_Entry_t root = { 0 };
22 m_file.writeBuffer(&root, sizeof(LFD_Entry_t));
23 m_fileList.MASTERN = 0;
24 m_fileList.entries = nullptr;
25
26 strcpy(m_archivePath, archivePath);
27 m_file.close();
28
29 return true;
30}
31
32bool LfdArchive::open(const char *archivePath)
33{

Callers

nothing calls this directly

Calls 3

openMethod · 0.45
writeBufferMethod · 0.45
closeMethod · 0.45

Tested by

no test coverage detected