From 0adbfba6c1b7a17c1f1746846011ba42875b6bf6 Mon Sep 17 00:00:00 2001 From: James Packer Date: Tue, 18 Aug 2026 19:07:35 +0100 Subject: [PATCH 1/6] Tidy up so utf8 to irrlicht stringw conversion happens as late as possible, using std::string instead of std::wstring before this. --- src/IniFile.cpp | 95 ------------------------------------------ src/IniFile.hpp | 2 - src/Lang.cpp | 15 +++---- src/ScenarioChoice.cpp | 4 +- src/editor/main.cpp | 4 +- 5 files changed, 12 insertions(+), 108 deletions(-) diff --git a/src/IniFile.cpp b/src/IniFile.cpp index ea5b7012b..f39df5c5c 100644 --- a/src/IniFile.cpp +++ b/src/IniFile.cpp @@ -36,26 +36,17 @@ class IniCache IniCache() = default; std::string getStringValue(const std::string &fileName, const std::string &key, const std::string &defValue = ""); - std::wstring getWStringValue(const std::string &fileName, const std::string &key, const std::wstring &defValue = L""); - irr::u32 getUIntValue(const std::string &fileName, const std::string &key, irr::u32 defValue = 0); irr::s32 getSIntValue(const std::string &fileName, const std::string &key, irr::s32 defValue = 0); irr::f32 getFloatValue(const std::string &fileName, const std::string &key, irr::f32 defValue = 0.f); private: bool readFile(const std::string &fileName); - - bool readWFile(const std::string &fileName); - -private: std::map> m_stringData; - std::map> m_wstringData; }; - static IniCache g_iniCache; - bool IniCache::readFile(const std::string& fileName) { if (m_stringData.find(fileName) != m_stringData.end()) { @@ -111,63 +102,6 @@ bool IniCache::readFile(const std::string& fileName) return true; } - -bool IniCache::readWFile(const std::string& fileName) -{ - if (m_stringData.find(fileName) != m_stringData.end()) { - return true; // file already read - } - - std::wifstream file(fileName.c_str()); - - //Set UTF-8 on Linux/OSX etc - #ifndef _WIN32 - try { - # ifdef __APPLE__ - char* thisLocale = setlocale(LC_ALL, ""); - if (thisLocale) { - file.imbue(std::locale(thisLocale)); - } - # else - file.imbue(std::locale("en_US.UTF8")); - # endif - } catch (const std::runtime_error& runtimeError) { - file.imbue(std::locale("")); - } - #endif - - if (!file.is_open()) { - if (IniFile::irrlichtLogger) { - std::string logMessage = "Unable to open file: "; - logMessage.append(fileName); - IniFile::irrlichtLogger->log(logMessage.c_str()); - } - else { - std::cerr << "Unable to open file " << fileName << std::endl; - } - return false; - } - - std::wstring line; - while ( std::getline (file,line) ) - { - const std::size_t equalsPos = line.find_first_of(L"="); - if (equalsPos != std::wstring::npos) { - std::wstring key = Utilities::trim(line.substr(0, equalsPos)); - std::wstring value = Utilities::trim(line.substr(equalsPos+1, std::wstring::npos)); - - Utilities::to_lower(key); - value = Utilities::trim(value, L"\""); - - m_wstringData[fileName][key] = value; - } - } - - file.close(); - return true; -} - - std::string IniCache::getStringValue(const std::string& fileName, const std::string& key, const std::string& defValue) { std::string keyLow = key; @@ -191,30 +125,6 @@ std::string IniCache::getStringValue(const std::string& fileName, const std::str return keyIt->second; } -std::wstring IniCache::getWStringValue(const std::string& fileName, const std::string& key, const std::wstring& defValue) -{ - std::wstring keyLow = std::wstring(key.begin(), key.end()); - Utilities::to_lower(keyLow); - - auto fileIt = m_wstringData.find(fileName); - if (fileIt == m_wstringData.end()) { - if (!readWFile(fileName)) { - // file not found - return defValue; - } - fileIt = m_wstringData.find(fileName); - assert(fileIt != m_wstringData.end()); - } - - const auto keyIt = fileIt->second.find(keyLow); - if (keyIt == (fileIt->second).end()) { - return defValue; - } - - return keyIt->second; - -} - irr::u32 IniCache::getUIntValue(const std::string& fileName, const std::string& key, irr::u32 defValue) { const std::string value = getStringValue(fileName, key, ""); @@ -290,11 +200,6 @@ namespace IniFile return g_iniCache.getStringValue(fileName, key, defValue); } - std::wstring iniFileToWString(const std::string &fileName, const std::string &key, const std::wstring &defValue) - { - return g_iniCache.getWStringValue(fileName, key, defValue); - } - //Load unsigned integer from an ini file irr::u32 iniFileTou32(const std::string &fileName, const std::string &key, irr::u32 defValue) { diff --git a/src/IniFile.hpp b/src/IniFile.hpp index 93c2f453f..82ae85fe2 100644 --- a/src/IniFile.hpp +++ b/src/IniFile.hpp @@ -28,8 +28,6 @@ namespace IniFile std::string enumerate2(std::string commandName, irr::s32 number1, irr::s32 number2); std::string iniFileToString(const std::string &fileName, const std::string &key, const std::string &defValue = ""); - std::wstring iniFileToWString(const std::string &fileName, const std::string &key, const std::wstring &defValue = L""); - irr::u32 iniFileTou32(const std::string &fileName, const std::string &key, irr::u32 defValue = 0); irr::s32 iniFileTos32(const std::string &fileName, const std::string &key, irr::s32 defValue = 0); irr::f32 iniFileTof32(const std::string &fileName, const std::string &key, irr::f32 defValue = 0.f); diff --git a/src/Lang.cpp b/src/Lang.cpp index 5588c10fe..eb78c9d35 100644 --- a/src/Lang.cpp +++ b/src/Lang.cpp @@ -28,9 +28,9 @@ Lang::Lang(std::string language) irr::core::stringw Lang::translate(std::string phraseName) { //Look up - std::wstring translatedPhrase = IniFile::iniFileToWString(languageFileName, phraseName); + std::string translatedPhrase = IniFile::iniFileToString(languageFileName, phraseName); //Fall back - if (translatedPhrase==L"") { + if (translatedPhrase=="") { if (phraseName == "deg") { //FIXME: Temp fix for the degree symbol, while utf-8 isn't properly sorted on all platforms wchar_t degSymbolChar = 176; @@ -39,21 +39,22 @@ irr::core::stringw Lang::translate(std::string phraseName) return degSymbolString; } else { std::cout << "Translation for " << phraseName << " not found in " << languageFileName << std::endl; - translatedPhrase = std::wstring(phraseName.begin(), phraseName.end()); + translatedPhrase = phraseName; } } //Convert '\n' characters within string to a newline - based on http://stackoverflow.com/a/24315631 size_t start_pos = 0; - std::wstring from = L"\\n"; - std::wstring to = L"\n"; - while((start_pos = translatedPhrase.find(from, start_pos)) != std::wstring::npos) { + std::string from = "\\n"; + std::string to = "\n"; + while((start_pos = translatedPhrase.find(from, start_pos)) != std::string::npos) { translatedPhrase.replace(start_pos, from.length(), to); start_pos += to.length(); // Handles case where 'to' is a substring of 'from' } //convert to stringw - irr::core::stringw returnPhrase(translatedPhrase.c_str()); + irr::core::stringw returnPhrase; + irr::core::multibyteToWString(returnPhrase, translatedPhrase.c_str()); return returnPhrase; } diff --git a/src/ScenarioChoice.cpp b/src/ScenarioChoice.cpp index 9ac609d54..2f0d83047 100644 --- a/src/ScenarioChoice.cpp +++ b/src/ScenarioChoice.cpp @@ -217,7 +217,7 @@ void ScenarioChoice::getScenarioList(std::vector&scenarioList, std: irr::io::path descriptionFilename = descriptionFilePath.append("/description.ini"); std::ifstream descriptionStream (descriptionFilename.c_str()); //Set UTF-8 on Linux/OSX etc - #ifndef _WIN32 + //#ifndef _WIN32 try { # ifdef __APPLE__ char* thisLocale = setlocale(LC_ALL, ""); @@ -230,7 +230,7 @@ void ScenarioChoice::getScenarioList(std::vector&scenarioList, std: } catch (const std::runtime_error& runtimeError) { descriptionStream.imbue(std::locale("")); } - #endif + //#endif std::string descriptionLines=""; if (descriptionStream.is_open()) { diff --git a/src/editor/main.cpp b/src/editor/main.cpp index 7d2233bb7..8ff3b4d57 100644 --- a/src/editor/main.cpp +++ b/src/editor/main.cpp @@ -627,7 +627,7 @@ int main (int argc, char ** argv) //Load description information std::ifstream descriptionStream (descriptionFilename.c_str()); //Set UTF-8 on Linux/OSX etc - #ifndef _WIN32 + //#ifndef _WIN32 try { # ifdef __APPLE__ char* thisLocale = setlocale(LC_ALL, ""); @@ -640,7 +640,7 @@ int main (int argc, char ** argv) } catch (const std::runtime_error& runtimeError) { descriptionStream.imbue(std::locale("")); } - #endif + //#endif std::string descriptionLines = ""; if (descriptionStream.is_open()) { From fb752ea927b8e3be7e2d709af6b3c5cbeaeb96ac Mon Sep 17 00:00:00 2001 From: James Packer Date: Thu, 20 Aug 2026 17:10:16 +0100 Subject: [PATCH 2/6] Convert UTF8 to ANSI strings on the fly. --- src/Lang.cpp | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/src/Lang.cpp b/src/Lang.cpp index eb78c9d35..78cb5e76b 100644 --- a/src/Lang.cpp +++ b/src/Lang.cpp @@ -18,6 +18,13 @@ #include "Lang.hpp" #include "IniFile.hpp" +#ifdef _WIN32 +// For UTF8 to ANSI conversion +#include +#include +#include +#endif // _WIN32 + //using namespace irr; Lang::Lang(std::string language) @@ -52,6 +59,16 @@ irr::core::stringw Lang::translate(std::string phraseName) start_pos += to.length(); // Handles case where 'to' is a substring of 'from' } +#ifdef _WIN32 + // If Windows, convert the UTF8 string to ANSI: + std::wstring_convert> wconv; + std::wstring wstr = wconv.from_bytes(translatedPhrase); + // wstring to string + std::vector buf(wstr.size()); + std::use_facet>(std::locale(".1252")).narrow(wstr.data(), wstr.data() + wstr.size(), '?', buf.data()); + translatedPhrase = std::string(buf.data(), buf.size()); +#endif + //convert to stringw irr::core::stringw returnPhrase; irr::core::multibyteToWString(returnPhrase, translatedPhrase.c_str()); From 68cc7369bad88d3727b41b4a3cc60c81f37729f3 Mon Sep 17 00:00:00 2001 From: James Packer Date: Thu, 20 Aug 2026 17:53:41 +0100 Subject: [PATCH 3/6] Update comment on language files --- bin/language-en.txt | 2 +- bin/language-es.txt | 2 +- bin/language-fr.txt | 2 +- bin/languageController-en.txt | 2 +- bin/languageController-es.txt | 2 +- bin/languageController-fr.txt | 2 +- bin/languageIniEditor-en.txt | 2 +- bin/languageIniEditor-es.txt | 2 +- bin/languageIniEditor-fr.txt | 2 +- bin/languageLauncher-en.txt | 2 +- bin/languageLauncher-es.txt | 2 +- bin/languageLauncher-fr.txt | 2 +- bin/languageMultiplayer-en.txt | 2 +- bin/languageMultiplayer-es.txt | 2 +- bin/languageMultiplayer-fr.txt | 2 +- bin/languageRepeater-en.txt | 2 +- bin/languageRepeater-es.txt | 2 +- bin/languageRepeater-fr.txt | 2 +- 18 files changed, 18 insertions(+), 18 deletions(-) diff --git a/bin/language-en.txt b/bin/language-en.txt index e8c2ba14b..2a7699037 100644 --- a/bin/language-en.txt +++ b/bin/language-en.txt @@ -1,7 +1,7 @@ Bridge Command Language file. To translate, please change the part after the 'equals' symbol The characters \n will be replaced with a line break, so multiple lines of text are possible -This file must be saved with default (ANSI) encoding on Windows, and UTF-8 encoding on other platforms (Linux, OSX, ...) +This file must be saved with UTF-8 encoding on all platforms ok="OK" scnChoose="Please choose a scenario:" diff --git a/bin/language-es.txt b/bin/language-es.txt index 02cb61797..9bc2db63d 100644 --- a/bin/language-es.txt +++ b/bin/language-es.txt @@ -1,7 +1,7 @@ Bridge Command Language file. To translate, please change the part after the 'equals' symbol The characters \n will be replaced with a line break, so multiple lines of text are possible -This file must be saved with default (ANSI) encoding on Windows, and UTF-8 encoding on other platforms (Linux, OSX, ...) +This file must be saved with UTF-8 encoding on all platforms ok="OK" scnChoose="Seleccione un escenario:" diff --git a/bin/language-fr.txt b/bin/language-fr.txt index 47312598c..20e571b27 100644 --- a/bin/language-fr.txt +++ b/bin/language-fr.txt @@ -1,7 +1,7 @@ Bridge Command Language file. To translate, please change the part after the 'equals' symbol The characters \n will be replaced with a line break, so multiple lines of text are possible -This file must be saved with default (ANSI) encoding on Windows, and UTF-8 encoding on other platforms (Linux, OSX, ...) +This file must be saved with UTF-8 encoding on all platforms ok="OK" scnChoose="Veuillez choisir un scénario :" diff --git a/bin/languageController-en.txt b/bin/languageController-en.txt index 8023567f9..95bfbefa9 100644 --- a/bin/languageController-en.txt +++ b/bin/languageController-en.txt @@ -1,7 +1,7 @@ Map Controller Language file. To translate, please change the part after the 'equals' symbol The characters \n will be replaced with a line break, so multiple lines of text are possible -This file must be saved with default (ANSI) encoding on Windows, and UTF-8 encoding on other platforms (Linux, OSX, ...) +This file must be saved with UTF-8 encoding on all platforms waiting = "Waiting..." startBC = "Please start the Bridge Command session. This computer's hostname and port is:" diff --git a/bin/languageController-es.txt b/bin/languageController-es.txt index 9cd529c71..0f0e21aeb 100644 --- a/bin/languageController-es.txt +++ b/bin/languageController-es.txt @@ -1,7 +1,7 @@ Map Controller Language file. To translate, please change the part after the 'equals' symbol The characters \n will be replaced with a line break, so multiple lines of text are possible -This file must be saved with default (ANSI) encoding on Windows, and UTF-8 encoding on other platforms (Linux, OSX, ...) +This file must be saved with UTF-8 encoding on all platforms waiting = "Espere..." startBC = "Abra una sesión de Bridge Command. El nombre y el puerto de este ordenador son:" diff --git a/bin/languageController-fr.txt b/bin/languageController-fr.txt index 42ef9eb9b..c5d4ba5c3 100644 --- a/bin/languageController-fr.txt +++ b/bin/languageController-fr.txt @@ -1,7 +1,7 @@ Map Controller Language file. To translate, please change the part after the 'equals' symbol The characters \n will be replaced with a line break, so multiple lines of text are possible -This file must be saved with default (ANSI) encoding on Windows, and UTF-8 encoding on other platforms (Linux, OSX, ...) +This file must be saved with UTF-8 encoding on all platforms waiting = "Patientez..." startBC = "Veuillez démarrer la session Bridge Command. Le nom et le port de cet ordinateur sont :" diff --git a/bin/languageIniEditor-en.txt b/bin/languageIniEditor-en.txt index 721788273..c7e1e3c46 100644 --- a/bin/languageIniEditor-en.txt +++ b/bin/languageIniEditor-en.txt @@ -1,7 +1,7 @@ Ini Editor Language file. To translate, please change the part after the 'equals' symbol The characters \n will be replaced with a line break, so multiple lines of text are possible -This file must be saved with default (ANSI) encoding on Windows, and UTF-8 encoding on other platforms (Linux, OSX, ...) +This file must be saved with UTF-8 encoding on all platforms name="Setting name" value="Setting value" diff --git a/bin/languageIniEditor-es.txt b/bin/languageIniEditor-es.txt index 5d7c6a62d..7d38168ff 100644 --- a/bin/languageIniEditor-es.txt +++ b/bin/languageIniEditor-es.txt @@ -1,7 +1,7 @@ Ini Editor Language file. To translate, please change the part after the 'equals' symbol The characters \n will be replaced with a line break, so multiple lines of text are possible -This file must be saved with default (ANSI) encoding on Windows, and UTF-8 encoding on other platforms (Linux, OSX, ...) +This file must be saved with UTF-8 encoding on all platforms name="Nombre de la variáble" value="Valor de la variable" diff --git a/bin/languageIniEditor-fr.txt b/bin/languageIniEditor-fr.txt index a2cb6ec00..0491412a8 100644 --- a/bin/languageIniEditor-fr.txt +++ b/bin/languageIniEditor-fr.txt @@ -1,7 +1,7 @@ Ini Editor Language file. To translate, please change the part after the 'equals' symbol The characters \n will be replaced with a line break, so multiple lines of text are possible -This file must be saved with default (ANSI) encoding on Windows, and UTF-8 encoding on other platforms (Linux, OSX, ...) +This file must be saved with UTF-8 encoding on all platforms name="Nom du paramètre" value="Valeur du paramètre" diff --git a/bin/languageLauncher-en.txt b/bin/languageLauncher-en.txt index 8906bdfd8..dffede4f5 100644 --- a/bin/languageLauncher-en.txt +++ b/bin/languageLauncher-en.txt @@ -1,7 +1,7 @@ Launcher Language file. To translate, please change the part after the 'equals' symbol The characters \n will be replaced with a line break, so multiple lines of text are possible -This file must be saved with default (ANSI) encoding on Windows, and UTF-8 encoding on other platforms (Linux, OSX, ...) +This file must be saved with UTF-8 encoding on all platforms startBC = "Start Bridge Command " startMC = "Map Controller " diff --git a/bin/languageLauncher-es.txt b/bin/languageLauncher-es.txt index 6a0596df8..d7d2d4236 100644 --- a/bin/languageLauncher-es.txt +++ b/bin/languageLauncher-es.txt @@ -1,7 +1,7 @@ Launcher Language file. To translate, please change the part after the 'equals' symbol The characters \n will be replaced with a line break, so multiple lines of text are possible -This file must be saved with default (ANSI) encoding on Windows, and UTF-8 encoding on other platforms (Linux, OSX, ...) +This file must be saved with UTF-8 encoding on all platforms startBC = "Abrir Bridge Command " startMC = "Map Controller " diff --git a/bin/languageLauncher-fr.txt b/bin/languageLauncher-fr.txt index 6a45ffe95..bdb9670a6 100644 --- a/bin/languageLauncher-fr.txt +++ b/bin/languageLauncher-fr.txt @@ -1,7 +1,7 @@ Launcher Language file. To translate, please change the part after the 'equals' symbol The characters \n will be replaced with a line break, so multiple lines of text are possible -This file must be saved with default (ANSI) encoding on Windows, and UTF-8 encoding on other platforms (Linux, OSX, ...) +This file must be saved with UTF-8 encoding on all platforms startBC = "Démarrer Bridge Command " startMC = "Contrôleur de carte " diff --git a/bin/languageMultiplayer-en.txt b/bin/languageMultiplayer-en.txt index 57a9b0ac4..c0dfacadc 100644 --- a/bin/languageMultiplayer-en.txt +++ b/bin/languageMultiplayer-en.txt @@ -1,7 +1,7 @@ Multiplayer Language file. To translate, please change the part after the 'equals' symbol The characters \n will be replaced with a line break, so multiple lines of text are possible -This file must be saved with default (ANSI) encoding on Windows, and UTF-8 encoding on other platforms (Linux, OSX, ...) +This file must be saved with UTF-8 encoding on all platforms scnChoose="Please choose a scenario:" hostname="Hostname (PC name) for each player.\nEntries should be comma separated." diff --git a/bin/languageMultiplayer-es.txt b/bin/languageMultiplayer-es.txt index 9bdc36c3f..a7968752f 100644 --- a/bin/languageMultiplayer-es.txt +++ b/bin/languageMultiplayer-es.txt @@ -1,7 +1,7 @@ Multiplayer Language file. To translate, please change the part after the 'equals' symbol The characters \n will be replaced with a line break, so multiple lines of text are possible -This file must be saved with default (ANSI) encoding on Windows, and UTF-8 encoding on other platforms (Linux, OSX, ...) +This file must be saved with UTF-8 encoding on all platforms scnChoose="Elija un escenario:" hostname="Nombre del PC servidor para cada jugador.\nLas máquinas deben separarse por comas." diff --git a/bin/languageMultiplayer-fr.txt b/bin/languageMultiplayer-fr.txt index f26341168..a3ba30036 100644 --- a/bin/languageMultiplayer-fr.txt +++ b/bin/languageMultiplayer-fr.txt @@ -1,7 +1,7 @@ Multiplayer Language file. To translate, please change the part after the 'equals' symbol The characters \n will be replaced with a line break, so multiple lines of text are possible -This file must be saved with default (ANSI) encoding on Windows, and UTF-8 encoding on other platforms (Linux, OSX, ...) +This file must be saved with UTF-8 encoding on all platforms scnChoose="Veuillez choisir un scénario :" hostname="Nom d'hôte (nom du PC) pour chaque joueur.\nLes entrées doivent être séparées par des virgules." diff --git a/bin/languageRepeater-en.txt b/bin/languageRepeater-en.txt index 56d026ad5..938e79cc4 100644 --- a/bin/languageRepeater-en.txt +++ b/bin/languageRepeater-en.txt @@ -1,7 +1,7 @@ Bridge Command Language file. To translate, please change the part after the 'equals' symbol The characters \n will be replaced with a line break, so multiple lines of text are possible -This file must be saved with default (ANSI) encoding on Windows, and UTF-8 encoding on other platforms (Linux, OSX, ...) +This file must be saved with UTF-8 encoding on all platforms moveMessage="Please move this message box to the monitor where the repeater should run, and click OK" diff --git a/bin/languageRepeater-es.txt b/bin/languageRepeater-es.txt index 4ee5e6bd1..d9914b398 100644 --- a/bin/languageRepeater-es.txt +++ b/bin/languageRepeater-es.txt @@ -1,7 +1,7 @@ Bridge Command Language file. To translate, please change the part after the 'equals' symbol The characters \n will be replaced with a line break, so multiple lines of text are possible -This file must be saved with default (ANSI) encoding on Windows, and UTF-8 encoding on other platforms (Linux, OSX, ...) +This file must be saved with UTF-8 encoding on all platforms moveMessage="Mueva esta ventana al monitor donde quiera el repetidor y haga click sobre OK." diff --git a/bin/languageRepeater-fr.txt b/bin/languageRepeater-fr.txt index 5ea822bb1..133097806 100644 --- a/bin/languageRepeater-fr.txt +++ b/bin/languageRepeater-fr.txt @@ -1,7 +1,7 @@ Bridge Command Language file. To translate, please change the part after the 'equals' symbol The characters \n will be replaced with a line break, so multiple lines of text are possible -This file must be saved with default (ANSI) encoding on Windows, and UTF-8 encoding on other platforms (Linux, OSX, ...) +This file must be saved with UTF-8 encoding on all platforms moveMessage="Veuillez déplacer cette fenêtre vers le moniteur où le répéteur doit être lancé, et cliquez sur OK." From 80494067422b2d970ce5c9798e461f6403f3ea90 Mon Sep 17 00:00:00 2001 From: James Packer Date: Thu, 20 Aug 2026 17:54:39 +0100 Subject: [PATCH 4/6] Copy Spanish language files into MacOS app --- bin/macOScopy | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/bin/macOScopy b/bin/macOScopy index 291fa390e..8de70392a 100755 --- a/bin/macOScopy +++ b/bin/macOScopy @@ -50,3 +50,9 @@ cp -a languageMultiplayer-fr.txt BridgeCommand.app/Contents/Resources/languageMu cp -a languageLauncher-fr.txt BridgeCommand.app/Contents/Resources/languageLauncher-fr.txt cp -a languageIniEditor-fr.txt BridgeCommand.app/Contents/Resources/languageIniEditor-fr.txt cp -a languageRepeater-fr.txt BridgeCommand.app/Contents/Resources/languageRepeater-fr.txt +cat language-es.txt | sed -E 's/Ctrl/Cmd/g' > BridgeCommand.app/Contents/Resources/language-es.txt +cp -a languageController-es.txt BridgeCommand.app/Contents/Resources/languageController-es.txt +cp -a languageMultiplayer-es.txt BridgeCommand.app/Contents/Resources/languageMultiplayer-es.txt +cp -a languageLauncher-es.txt BridgeCommand.app/Contents/Resources/languageLauncher-es.txt +cp -a languageIniEditor-es.txt BridgeCommand.app/Contents/Resources/languageIniEditor-es.txt +cp -a languageRepeater-es.txt BridgeCommand.app/Contents/Resources/languageRepeater-es.txt \ No newline at end of file From 6943b54c9580efb344e7a5e63283dac637b5be13 Mon Sep 17 00:00:00 2001 From: James Packer Date: Thu, 20 Aug 2026 18:25:48 +0100 Subject: [PATCH 5/6] Add missing newline --- bin/macOScopy | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/macOScopy b/bin/macOScopy index 8de70392a..bfbc917c2 100755 --- a/bin/macOScopy +++ b/bin/macOScopy @@ -55,4 +55,4 @@ cp -a languageController-es.txt BridgeCommand.app/Contents/Resources/languageCon cp -a languageMultiplayer-es.txt BridgeCommand.app/Contents/Resources/languageMultiplayer-es.txt cp -a languageLauncher-es.txt BridgeCommand.app/Contents/Resources/languageLauncher-es.txt cp -a languageIniEditor-es.txt BridgeCommand.app/Contents/Resources/languageIniEditor-es.txt -cp -a languageRepeater-es.txt BridgeCommand.app/Contents/Resources/languageRepeater-es.txt \ No newline at end of file +cp -a languageRepeater-es.txt BridgeCommand.app/Contents/Resources/languageRepeater-es.txt From ffa50a4838e3a556b6a8d3f9f792a9ceb809b5a1 Mon Sep 17 00:00:00 2001 From: James Packer Date: Thu, 20 Aug 2026 18:26:27 +0100 Subject: [PATCH 6/6] Revert unnecessary changes --- src/ScenarioChoice.cpp | 4 ++-- src/editor/main.cpp | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/ScenarioChoice.cpp b/src/ScenarioChoice.cpp index 2f0d83047..9ac609d54 100644 --- a/src/ScenarioChoice.cpp +++ b/src/ScenarioChoice.cpp @@ -217,7 +217,7 @@ void ScenarioChoice::getScenarioList(std::vector&scenarioList, std: irr::io::path descriptionFilename = descriptionFilePath.append("/description.ini"); std::ifstream descriptionStream (descriptionFilename.c_str()); //Set UTF-8 on Linux/OSX etc - //#ifndef _WIN32 + #ifndef _WIN32 try { # ifdef __APPLE__ char* thisLocale = setlocale(LC_ALL, ""); @@ -230,7 +230,7 @@ void ScenarioChoice::getScenarioList(std::vector&scenarioList, std: } catch (const std::runtime_error& runtimeError) { descriptionStream.imbue(std::locale("")); } - //#endif + #endif std::string descriptionLines=""; if (descriptionStream.is_open()) { diff --git a/src/editor/main.cpp b/src/editor/main.cpp index 8ff3b4d57..7d2233bb7 100644 --- a/src/editor/main.cpp +++ b/src/editor/main.cpp @@ -627,7 +627,7 @@ int main (int argc, char ** argv) //Load description information std::ifstream descriptionStream (descriptionFilename.c_str()); //Set UTF-8 on Linux/OSX etc - //#ifndef _WIN32 + #ifndef _WIN32 try { # ifdef __APPLE__ char* thisLocale = setlocale(LC_ALL, ""); @@ -640,7 +640,7 @@ int main (int argc, char ** argv) } catch (const std::runtime_error& runtimeError) { descriptionStream.imbue(std::locale("")); } - //#endif + #endif std::string descriptionLines = ""; if (descriptionStream.is_open()) {