🐛 Do not utilize translations till after it has been initialize

This commit is contained in:
Anders Jenbo 2021-05-01 06:49:24 +02:00
commit 38d7b1e3c8
4 changed files with 21 additions and 19 deletions

View file

@ -77,11 +77,6 @@ HANDLE init_test_access(const std::vector<std::string> &paths, const char *mpq_n
} // namespace
/* data */
char gszVersionNumber[64] = "internal version unknown";
char gszProductName[64] = "DevilutionX vUnknown";
void init_cleanup()
{
if (gbIsMultiplayer && gbRunGame) {
@ -140,16 +135,8 @@ void init_cleanup()
NetClose();
}
static void init_get_file_info()
{
snprintf(gszProductName, sizeof(gszProductName) / sizeof(char), "%s v%s", PROJECT_NAME, PROJECT_VERSION);
snprintf(gszVersionNumber, sizeof(gszVersionNumber) / sizeof(char), _("version %s"), PROJECT_VERSION);
}
void init_archives()
{
init_get_file_info();
std::vector<std::string> paths;
paths.reserve(5);
paths.push_back(paths::BasePath());