diff options
| author | KiritoDv <kiritodev01@gmail.com> | 2023-09-24 03:28:51 -0600 |
|---|---|---|
| committer | KiritoDv <kiritodev01@gmail.com> | 2023-09-24 03:28:51 -0600 |
| commit | 48f52849d052ee60d961bc9e2646e0f33f4fa898 (patch) | |
| tree | 21fb5435d71aaaf7dc31043ba59d9773621c293c /src/Companion.cpp | |
| parent | 5d07dcb92553deff0dc8de0ff7c5822af131f245 (diff) | |
Fixed otrs on windows
Diffstat (limited to 'src/Companion.cpp')
| -rw-r--r-- | src/Companion.cpp | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/src/Companion.cpp b/src/Companion.cpp index 5d7607a..f18d3c6 100644 --- a/src/Companion.cpp +++ b/src/Companion.cpp @@ -83,11 +83,14 @@ void Companion::Process() { } auto buffer = write.ToVector(); - auto output = entry.path().stem() / asset->first.as<std::string>(); - wrapper.CreateFile(output.string(), buffer); + auto output = (entry.path().stem() / asset->first.as<std::string>()).string(); + + std::replace(output.begin(), output.end(), '\\', '/'); + + wrapper.CreateFile(output, buffer); if(type != "TEXTURE") { - std::string dpath = "debug/" + output.string(); + std::string dpath = "debug/" + output; if(!fs::exists(fs::path(dpath).parent_path())){ fs::create_directories(fs::path(dpath).parent_path()); } |
