Add asset loader for localize files

This commit is contained in:
Jan
2021-03-23 17:16:36 +01:00
parent 3ed63415a7
commit 79c1284193
50 changed files with 609 additions and 23 deletions

View File

@ -3,7 +3,7 @@
#include <fstream>
#include <filesystem>
#include "Dumping/Localize/LocalizeCommon.h"
#include "Localize/LocalizeCommon.h"
#include "Dumping/Localize/StringFileDumper.h"
using namespace T6;
@ -17,13 +17,12 @@ void AssetDumperLocalizeEntry::DumpPool(AssetDumpingContext& context, AssetPool<
const auto language = LocalizeCommon::GetNameOfLanguage(context.m_zone->m_language);
fs::path stringsPath(context.m_base_path);
stringsPath.append(language);
stringsPath.append("/localizedstrings");
stringsPath.append("localizedstrings");
create_directories(stringsPath);
auto stringFilePath(stringsPath);
stringFilePath.append(context.m_zone->m_name);
stringFilePath.append(".str");
stringFilePath.append(context.m_zone->m_name + ".str");
std::ofstream stringFile(stringFilePath, std::fstream::out | std::ofstream::binary);