From 0f292ff218c0e173d72624cc794f66d010bdf5d6 Mon Sep 17 00:00:00 2001 From: Vlad Date: Sun, 2 Oct 2022 23:08:59 +0300 Subject: [PATCH] Dont always load eng ff (#297) --- .../{ => h1_mod_common}/fonts/default.otf | Bin .../localizedstrings/english.json | 92 ++++++++++++++++++ data/zonetool/localizedstrings/english.json | 91 ----------------- .../localizedstrings/english_safe.json | 91 ----------------- src/client/component/fastfiles.cpp | 5 +- 5 files changed, 96 insertions(+), 183 deletions(-) rename data/zonetool/{ => h1_mod_common}/fonts/default.otf (100%) create mode 100644 data/zonetool/h1_mod_common/localizedstrings/english.json diff --git a/data/zonetool/fonts/default.otf b/data/zonetool/h1_mod_common/fonts/default.otf similarity index 100% rename from data/zonetool/fonts/default.otf rename to data/zonetool/h1_mod_common/fonts/default.otf diff --git a/data/zonetool/h1_mod_common/localizedstrings/english.json b/data/zonetool/h1_mod_common/localizedstrings/english.json new file mode 100644 index 00000000..c07118fd --- /dev/null +++ b/data/zonetool/h1_mod_common/localizedstrings/english.json @@ -0,0 +1,92 @@ +{ + "CUSTOM_DEPOT_EULA_1": "Dear User,", + "CUSTOM_DEPOT_EULA_2": "By using this feature, you acknowledge that you are over the age of 18 years old, and that any sort of gambling is allowed in your country. (even if they do not involve real money)", + "CUSTOM_DEPOT_EULA_3": "The H1-mod team is not responsible if you break any law within your country, and the sole responsibility will be upon you to respect the same.", + "CUSTOM_DEPOT_EULA_4": "The H1-mod team will never include real money transactions within the modified systems. The only way to get currency, should you wish to, is by playing the game.", + "CUSTOM_DEPOT_EULA_5": "Best regards,", + "CUSTOM_DEPOT_EULA_6": "The H1-mod team.", + + "LUA_MENU_FPS": "FPS Counter", + "LUA_MENU_FPS_DESC": "Show FPS counter.", + "LUA_MENU_LATENCY": "Server Latency", + "LUA_MENU_LATENCY_DESC": "Show server latency.", + "LUA_MENU_RED_DOT_BRIGHTNESS": "Red Dot Brightness", + "LUA_MENU_RED_DOT_BRIGHTNESS_DESC": "Adjust the brightness of red dot reticles.", + + "MENU_SYSINFO_CUSTOMER_SUPPORT_URL": "https://h1.gg/", + + "MENU_MODS": "MODS", + "MENU_MODS_DESC": "Load installed mods.", + "LUA_MENU_MOD_DESC_DEFAULT": "Load &&1.", + "LUA_MENU_MOD_DESC": "&&1\nAuthor: &&2\nVersion: &&3", + "LUA_MENU_LOADED_MOD": "Loaded mod: ^2&&1", + "LUA_MENU_AVAILABLE_MODS": "Available mods", + "LUA_MENU_UNLOAD": "Unload", + "LUA_MENU_UNLOAD_DESC": "Unload the currently loaded mod.", + + "PLATFORM_SHADER_PRECACHE_ASK": "Would you like to populate the shader cache? It may cause crashes with certain GPUs (e.g. RTX cards) but will improve performance if successful.", + "MENU_NO_DONT_ASK": "No, don't ask me again", + + "LUA_MENU_SERVERLIST": "SERVER LIST", + "MENU_NUMPLAYERS": "Players", + "MENU_PING": "Ping", + "SERVERLIST_PLAYER_COUNT": "&&1 Players", + "SERVERLIST_SERVER_COUNT": "&&1 Servers", + + "LUA_MENU_STATS": "Stats", + "LUA_MENU_STATS_DESC": "Edit player stats settings.", + "LUA_MENU_UNLOCKALL_ITEMS": "Unlock all items", + "LUA_MENU_UNLOCKALL_ITEMS_DESC": "Whether items should be locked based on the player's stats or always unlocked.", + "LUA_MENU_UNLOCKALL_LOOT": "Unlock all loot", + "LUA_MENU_UNLOCKALL_LOOT_DESC": "Whether loot should be locked based on the player's stats or always unlocked.", + "LUA_MENU_UNLOCKALL_CLASSES": "Unlock all classes", + "LUA_MENU_UNLOCKALL_CLASSES_DESC": "Whether classes should be locked based on the player's stats or always unlocked.", + "LUA_MENU_PRESTIGE": "Prestige", + "LUA_MENU_PRESTIGE_DESC": "Edit prestige level.", + "LUA_MENU_RANK": "Rank", + "LUA_MENU_RANK_DESC": "Edit rank.", + "LUA_MENU_UNSAVED_CHANGES": "You have unsaved changes: are you sure you want to exit?", + "LUA_MENU_SAVE": "Save changes", + "LUA_MENU_SAVE_DESC": "Save changes.", + "LUA_MENU_SETTINGS": "Settings", + "LUA_MENU_EDIT_STATS": "Edit Stats", + + "UPDATER_POPUP_NO_UPDATES_AVAILABLE": "No updates available", + "UPDATER_POPUP_AVAILABLE_UPDATE_TEXT": "An update is available, proceed with installation?", + "UPDATER_POPUP_SUCCESSFUL": "Update successful", + "UPDATER_POPUP_RESTART_POPUP_TEXT": "Update requires restart", + "UPDATER_POPUP_CHECKING_FOR_UPDATES": "Checking for updates...", + + "MPHUD_FPS": "FPS: ", + "MPHUD_LATENCY": "Latency: ", + "MPHUD_LATENCY_MS": " ms", + "LUA_MENU_TELEMETRY": "TELEMETRY", + + "MENU_ENGLISH": "English", + "MENU_ENGLISH_SAFE": "English (Safe)", + "MENU_FRENCH": "Français", + "MENU_GERMAN": "Deutsch", + "MENU_ITALIAN": "Italiano", + "MENU_JAPANESE_PARTIAL": "日本語(一部)", + "MENU_KOREAN": "한국어", + "MENU_POLISH": "Polski", + "MENU_PORTUGUESE": "Português", + "MENU_RUSSIAN": "Русский", + "MENU_SIMPLIFIED_CHINESE": "简体中文", + "MENU_SPANISH": "Español", + "MENU_TRADITIONAL_CHINESE": "繁體中文", + + "LOCALE_ENGLISH": "English", + "LOCALE_ENGLISH_SAFE": "English (Safe)", + "LOCALE_FRENCH": "French", + "LOCALE_GERMAN": "German", + "LOCALE_ITALIAN": "Italian", + "LOCALE_JAPANESE_PARTIAL": "Japanese (Partial)", + "LOCALE_KOREAN": "Korean", + "LOCALE_POLISH": "Polish", + "LOCALE_PORTUGUESE": "Portuguese", + "LOCALE_RUSSIAN": "Russian", + "LOCALE_SIMPLIFIED_CHINESE": "Simplified Chinese", + "LOCALE_SPANISH": "Spanish", + "LOCALE_TRADITIONAL_CHINESE": "Traditional Chinese" +} \ No newline at end of file diff --git a/data/zonetool/localizedstrings/english.json b/data/zonetool/localizedstrings/english.json index 052f0381..915ac1d1 100644 --- a/data/zonetool/localizedstrings/english.json +++ b/data/zonetool/localizedstrings/english.json @@ -1,95 +1,4 @@ { - "CUSTOM_DEPOT_EULA_1": "Dear User,", - "CUSTOM_DEPOT_EULA_2": "By using this feature, you acknowledge that you are over the age of 18 years old, and that any sort of gambling is allowed in your country. (even if they do not involve real money)", - "CUSTOM_DEPOT_EULA_3": "The H1-mod team is not responsible if you break any law within your country, and the sole responsibility will be upon you to respect the same.", - "CUSTOM_DEPOT_EULA_4": "The H1-mod team will never include real money transactions within the modified systems. The only way to get currency, should you wish to, is by playing the game.", - "CUSTOM_DEPOT_EULA_5": "Best regards,", - "CUSTOM_DEPOT_EULA_6": "The H1-mod team.", - - "LUA_MENU_FPS": "FPS Counter", - "LUA_MENU_FPS_DESC": "Show FPS counter.", - "LUA_MENU_LATENCY": "Server Latency", - "LUA_MENU_LATENCY_DESC": "Show server latency.", - "LUA_MENU_RED_DOT_BRIGHTNESS": "Red Dot Brightness", - "LUA_MENU_RED_DOT_BRIGHTNESS_DESC": "Adjust the brightness of red dot reticles.", - - "MENU_SYSINFO_CUSTOMER_SUPPORT_URL": "https://h1.gg/", - - "MENU_MODS": "MODS", - "MENU_MODS_DESC": "Load installed mods.", - "LUA_MENU_MOD_DESC_DEFAULT": "Load &&1.", - "LUA_MENU_MOD_DESC": "&&1\nAuthor: &&2\nVersion: &&3", - "LUA_MENU_LOADED_MOD": "Loaded mod: ^2&&1", - "LUA_MENU_AVAILABLE_MODS": "Available mods", - "LUA_MENU_UNLOAD": "Unload", - "LUA_MENU_UNLOAD_DESC": "Unload the currently loaded mod.", - - "PLATFORM_SHADER_PRECACHE_ASK": "Would you like to populate the shader cache? It may cause crashes with certain GPUs (e.g. RTX cards) but will improve performance if successful.", - "MENU_NO_DONT_ASK": "No, don't ask me again", - - "LUA_MENU_SERVERLIST": "SERVER LIST", - "MENU_NUMPLAYERS": "Players", - "MENU_PING": "Ping", - "SERVERLIST_PLAYER_COUNT": "&&1 Players", - "SERVERLIST_SERVER_COUNT": "&&1 Servers", - - "LUA_MENU_STATS": "Stats", - "LUA_MENU_STATS_DESC": "Edit player stats settings.", - "LUA_MENU_UNLOCKALL_ITEMS": "Unlock all items", - "LUA_MENU_UNLOCKALL_ITEMS_DESC": "Whether items should be locked based on the player's stats or always unlocked.", - "LUA_MENU_UNLOCKALL_LOOT": "Unlock all loot", - "LUA_MENU_UNLOCKALL_LOOT_DESC": "Whether loot should be locked based on the player's stats or always unlocked.", - "LUA_MENU_UNLOCKALL_CLASSES": "Unlock all classes", - "LUA_MENU_UNLOCKALL_CLASSES_DESC": "Whether classes should be locked based on the player's stats or always unlocked.", - "LUA_MENU_PRESTIGE": "Prestige", - "LUA_MENU_PRESTIGE_DESC": "Edit prestige level.", - "LUA_MENU_RANK": "Rank", - "LUA_MENU_RANK_DESC": "Edit rank.", - "LUA_MENU_UNSAVED_CHANGES": "You have unsaved changes: are you sure you want to exit?", - "LUA_MENU_SAVE": "Save changes", - "LUA_MENU_SAVE_DESC": "Save changes.", - "LUA_MENU_SETTINGS": "Settings", - "LUA_MENU_EDIT_STATS": "Edit Stats", - - "UPDATER_POPUP_NO_UPDATES_AVAILABLE": "No updates available", - "UPDATER_POPUP_AVAILABLE_UPDATE_TEXT": "An update is available, proceed with installation?", - "UPDATER_POPUP_SUCCESSFUL": "Update successful", - "UPDATER_POPUP_RESTART_POPUP_TEXT": "Update requires restart", - "UPDATER_POPUP_CHECKING_FOR_UPDATES": "Checking for updates...", - - "MPHUD_FPS": "FPS: ", - "MPHUD_LATENCY": "Latency: ", - "MPHUD_LATENCY_MS": " ms", - "LUA_MENU_TELEMETRY": "TELEMETRY", - - "MENU_ENGLISH": "English", - "MENU_ENGLISH_SAFE": "English (Safe)", - "MENU_FRENCH": "Français", - "MENU_GERMAN": "Deutsch", - "MENU_ITALIAN": "Italiano", - "MENU_JAPANESE_PARTIAL": "日本語(一部)", - "MENU_KOREAN": "한국어", - "MENU_POLISH": "Polski", - "MENU_PORTUGUESE": "Português", - "MENU_RUSSIAN": "Русский", - "MENU_SIMPLIFIED_CHINESE": "简体中文", - "MENU_SPANISH": "Español", - "MENU_TRADITIONAL_CHINESE": "繁體中文", - - "LOCALE_ENGLISH": "English", - "LOCALE_ENGLISH_SAFE": "English (Safe)", - "LOCALE_FRENCH": "French", - "LOCALE_GERMAN": "German", - "LOCALE_ITALIAN": "Italian", - "LOCALE_JAPANESE_PARTIAL": "Japanese (Partial)", - "LOCALE_KOREAN": "Korean", - "LOCALE_POLISH": "Polish", - "LOCALE_PORTUGUESE": "Portuguese", - "LOCALE_RUSSIAN": "Russian", - "LOCALE_SIMPLIFIED_CHINESE": "Simplified Chinese", - "LOCALE_SPANISH": "Spanish", - "LOCALE_TRADITIONAL_CHINESE": "Traditional Chinese", - "LUA_MENU_CHOOSE_LANGUAGE": "Choose your language", "MENU_APPLY_LANGUAGE_SETTINGS": "Apply language settings?" } \ No newline at end of file diff --git a/data/zonetool/localizedstrings/english_safe.json b/data/zonetool/localizedstrings/english_safe.json index 052f0381..915ac1d1 100644 --- a/data/zonetool/localizedstrings/english_safe.json +++ b/data/zonetool/localizedstrings/english_safe.json @@ -1,95 +1,4 @@ { - "CUSTOM_DEPOT_EULA_1": "Dear User,", - "CUSTOM_DEPOT_EULA_2": "By using this feature, you acknowledge that you are over the age of 18 years old, and that any sort of gambling is allowed in your country. (even if they do not involve real money)", - "CUSTOM_DEPOT_EULA_3": "The H1-mod team is not responsible if you break any law within your country, and the sole responsibility will be upon you to respect the same.", - "CUSTOM_DEPOT_EULA_4": "The H1-mod team will never include real money transactions within the modified systems. The only way to get currency, should you wish to, is by playing the game.", - "CUSTOM_DEPOT_EULA_5": "Best regards,", - "CUSTOM_DEPOT_EULA_6": "The H1-mod team.", - - "LUA_MENU_FPS": "FPS Counter", - "LUA_MENU_FPS_DESC": "Show FPS counter.", - "LUA_MENU_LATENCY": "Server Latency", - "LUA_MENU_LATENCY_DESC": "Show server latency.", - "LUA_MENU_RED_DOT_BRIGHTNESS": "Red Dot Brightness", - "LUA_MENU_RED_DOT_BRIGHTNESS_DESC": "Adjust the brightness of red dot reticles.", - - "MENU_SYSINFO_CUSTOMER_SUPPORT_URL": "https://h1.gg/", - - "MENU_MODS": "MODS", - "MENU_MODS_DESC": "Load installed mods.", - "LUA_MENU_MOD_DESC_DEFAULT": "Load &&1.", - "LUA_MENU_MOD_DESC": "&&1\nAuthor: &&2\nVersion: &&3", - "LUA_MENU_LOADED_MOD": "Loaded mod: ^2&&1", - "LUA_MENU_AVAILABLE_MODS": "Available mods", - "LUA_MENU_UNLOAD": "Unload", - "LUA_MENU_UNLOAD_DESC": "Unload the currently loaded mod.", - - "PLATFORM_SHADER_PRECACHE_ASK": "Would you like to populate the shader cache? It may cause crashes with certain GPUs (e.g. RTX cards) but will improve performance if successful.", - "MENU_NO_DONT_ASK": "No, don't ask me again", - - "LUA_MENU_SERVERLIST": "SERVER LIST", - "MENU_NUMPLAYERS": "Players", - "MENU_PING": "Ping", - "SERVERLIST_PLAYER_COUNT": "&&1 Players", - "SERVERLIST_SERVER_COUNT": "&&1 Servers", - - "LUA_MENU_STATS": "Stats", - "LUA_MENU_STATS_DESC": "Edit player stats settings.", - "LUA_MENU_UNLOCKALL_ITEMS": "Unlock all items", - "LUA_MENU_UNLOCKALL_ITEMS_DESC": "Whether items should be locked based on the player's stats or always unlocked.", - "LUA_MENU_UNLOCKALL_LOOT": "Unlock all loot", - "LUA_MENU_UNLOCKALL_LOOT_DESC": "Whether loot should be locked based on the player's stats or always unlocked.", - "LUA_MENU_UNLOCKALL_CLASSES": "Unlock all classes", - "LUA_MENU_UNLOCKALL_CLASSES_DESC": "Whether classes should be locked based on the player's stats or always unlocked.", - "LUA_MENU_PRESTIGE": "Prestige", - "LUA_MENU_PRESTIGE_DESC": "Edit prestige level.", - "LUA_MENU_RANK": "Rank", - "LUA_MENU_RANK_DESC": "Edit rank.", - "LUA_MENU_UNSAVED_CHANGES": "You have unsaved changes: are you sure you want to exit?", - "LUA_MENU_SAVE": "Save changes", - "LUA_MENU_SAVE_DESC": "Save changes.", - "LUA_MENU_SETTINGS": "Settings", - "LUA_MENU_EDIT_STATS": "Edit Stats", - - "UPDATER_POPUP_NO_UPDATES_AVAILABLE": "No updates available", - "UPDATER_POPUP_AVAILABLE_UPDATE_TEXT": "An update is available, proceed with installation?", - "UPDATER_POPUP_SUCCESSFUL": "Update successful", - "UPDATER_POPUP_RESTART_POPUP_TEXT": "Update requires restart", - "UPDATER_POPUP_CHECKING_FOR_UPDATES": "Checking for updates...", - - "MPHUD_FPS": "FPS: ", - "MPHUD_LATENCY": "Latency: ", - "MPHUD_LATENCY_MS": " ms", - "LUA_MENU_TELEMETRY": "TELEMETRY", - - "MENU_ENGLISH": "English", - "MENU_ENGLISH_SAFE": "English (Safe)", - "MENU_FRENCH": "Français", - "MENU_GERMAN": "Deutsch", - "MENU_ITALIAN": "Italiano", - "MENU_JAPANESE_PARTIAL": "日本語(一部)", - "MENU_KOREAN": "한국어", - "MENU_POLISH": "Polski", - "MENU_PORTUGUESE": "Português", - "MENU_RUSSIAN": "Русский", - "MENU_SIMPLIFIED_CHINESE": "简体中文", - "MENU_SPANISH": "Español", - "MENU_TRADITIONAL_CHINESE": "繁體中文", - - "LOCALE_ENGLISH": "English", - "LOCALE_ENGLISH_SAFE": "English (Safe)", - "LOCALE_FRENCH": "French", - "LOCALE_GERMAN": "German", - "LOCALE_ITALIAN": "Italian", - "LOCALE_JAPANESE_PARTIAL": "Japanese (Partial)", - "LOCALE_KOREAN": "Korean", - "LOCALE_POLISH": "Polish", - "LOCALE_PORTUGUESE": "Portuguese", - "LOCALE_RUSSIAN": "Russian", - "LOCALE_SIMPLIFIED_CHINESE": "Simplified Chinese", - "LOCALE_SPANISH": "Spanish", - "LOCALE_TRADITIONAL_CHINESE": "Traditional Chinese", - "LUA_MENU_CHOOSE_LANGUAGE": "Choose your language", "MENU_APPLY_LANGUAGE_SETTINGS": "Apply language settings?" } \ No newline at end of file diff --git a/src/client/component/fastfiles.cpp b/src/client/component/fastfiles.cpp index b4b4de43..222b04ac 100644 --- a/src/client/component/fastfiles.cpp +++ b/src/client/component/fastfiles.cpp @@ -151,7 +151,10 @@ namespace fastfiles if (localized) { const auto language = game::SEH_GetCurrentLanguageCode(); - try_load_zone(language + "_"s + name, false); + if (!try_load_zone(language + "_"s + name, false) && language != "eng"s) + { + try_load_zone("eng_" + name, false); + } } if (!fastfiles::exists(name))