From 48f52849d052ee60d961bc9e2646e0f33f4fa898 Mon Sep 17 00:00:00 2001 From: KiritoDv Date: Sun, 24 Sep 2023 03:28:51 -0600 Subject: Fixed otrs on windows --- src/Companion.cpp | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'src/Companion.cpp') 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(); - wrapper.CreateFile(output.string(), buffer); + auto output = (entry.path().stem() / asset->first.as()).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()); } -- cgit v1.2.3