MCPcopy Create free account
hub / github.com/GarageGames/Torque3D / MountZips

Function MountZips

Engine/source/platform/platformVolume.cpp:59–81  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

57}
58
59bool MountZips(const String &root)
60{
61 Path basePath;
62 basePath.setRoot(root);
63 Vector<String> outList;
64
65 S32 num = FindByPattern(basePath, "*.zip", true, outList);
66 if(num == 0)
67 return true; // not an error
68
69 S32 mounted = 0;
70 for(S32 i = 0;i < outList.size();++i)
71 {
72 String &zipfile = outList[i];
73#ifdef TORQUE_ZIP_DISK_LAYOUT
74 mounted += (S32)Mount(root, new ZipFileSystem(zipfile, false));
75#else
76 mounted += (S32)Mount(root, new ZipFileSystem(zipfile, true));
77#endif
78 }
79
80 return mounted == outList.size();
81}
82
83//-----------------------------------------------------------------------------
84

Callers 1

MountDefaultsFunction · 0.85

Calls 4

FindByPatternFunction · 0.85
MountFunction · 0.85
setRootMethod · 0.45
sizeMethod · 0.45

Tested by

no test coverage detected