MCPcopy Create free account
hub / github.com/AbyssEngine/AbyssEngineOld / fixPath

Function fixPath

src/Abyss/FileSystem/MPQ.cpp:30–38  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

28};
29
30inline std::string fixPath(const std::string_view str) {
31 std::string result(str);
32 std::ranges::replace(result, '/', '\\');
33 if (result.starts_with('\\')) {
34 return result.substr(1);
35 }
36
37 return result;
38}
39
40MPQStream::MPQStream(HANDLE mpq, const std::string &fileName) {
41 if (!SFileOpenFileEx(mpq, fileName.c_str(), SFILE_OPEN_FROM_MPQ, &_mpqFile)) {

Callers 2

hasMethod · 0.85
loadMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected