diff --git a/Client/core/CCore.cpp b/Client/core/CCore.cpp index 910912dbc56..9202ce60529 100644 --- a/Client/core/CCore.cpp +++ b/Client/core/CCore.cpp @@ -834,12 +834,27 @@ void CCore::ApplyHooks() // Create our hooks. m_pDirectInputHookManager->ApplyHook(); - // m_pDirect3DHookManager->ApplyHook ( ); m_pSetCursorPosHook->ApplyHook(); // Remove useless DirectPlay dependency (dpnhpast.dll) @ 0x745701 // We have to patch here as multiplayer_sa and game_sa are loaded too late DetourLibraryFunction("kernel32.dll", "LoadLibraryA", Win32LoadLibraryA, SkipDirectPlay_LoadLibraryA); + + // Disable code that disallows multiple instances of GTA:SA + // Disable `if (IsAppAlreadyRunning())` in WinMain + { + DWORD oldProtect; + VirtualProtect(reinterpret_cast(0x74872D), 9, PAGE_READWRITE, &oldProtect); + memcpy(reinterpret_cast(0x74872D), "\x90\x90\x90\x90\x90\x90\x90\x90\x90", 9); + VirtualProtect(reinterpret_cast(0x74872D), 9, oldProtect, &oldProtect); + } + // Create an unnamed semaphore in CdStreamInitThread. + { + DWORD oldProtect; + VirtualProtect(reinterpret_cast(0x406945), 5, PAGE_READWRITE, &oldProtect); + memcpy(reinterpret_cast(0x406945), "\x6A\x00\x90\x90\x90", 5); + VirtualProtect(reinterpret_cast(0x406945), 5, oldProtect, &oldProtect); + } } bool UsingAltD3DSetup() diff --git a/Client/loader/CInstallManager.cpp b/Client/loader/CInstallManager.cpp index 0f1b9f9728c..9f7ceb59c24 100644 --- a/Client/loader/CInstallManager.cpp +++ b/Client/loader/CInstallManager.cpp @@ -361,17 +361,14 @@ SString CInstallManager::_ChangeToAdmin() NULL, SString(_("MTA:SA needs Administrator access for the following task:\n\n '%s'\n\nPlease confirm in the next window."), *m_strAdminReason), "Multi Theft Auto: San Andreas", MB_OK | MB_ICONINFORMATION | MB_TOPMOST); SetIsBlockingUserProcess(); - ReleaseSingleInstanceMutex(); if (ShellExecuteBlocking("runas", GetLauncherPathFilename(), GetSequencerSnapshot())) { // Will return here once admin process has finished - CreateSingleInstanceMutex(); UpdateSettingsForReportLog(); RestoreSequencerFromSnapshot(ReceiveStringFromAdminProcess()); ClearIsBlockingUserProcess(); return "ok"; // This will appear as the result for _ChangeFromAdmin } - CreateSingleInstanceMutex(); ClearIsBlockingUserProcess(); MessageBoxUTF8(NULL, SString(_("MTA:SA could not complete the following task:\n\n '%s'\n"), *m_strAdminReason), "Multi Theft Auto: San Andreas" + _E("CL01"), MB_OK | MB_ICONWARNING | MB_TOPMOST); @@ -478,10 +475,9 @@ SString CInstallManager::_MaybeSwitchToTempExe() // If a new "Multi Theft Auto.exe" exists, let that complete the install if (m_pSequencer->GetVariable(INSTALL_LOCATION) == "far") { - ReleaseSingleInstanceMutex(); if (ShellExecuteNonBlocking("open", GetLauncherPathFilename(), GetSequencerSnapshot())) ExitProcess(0); // All done here - CreateSingleInstanceMutex(); + return "fail"; } return "ok"; @@ -501,10 +497,9 @@ SString CInstallManager::_SwitchBackFromTempExe() { m_pSequencer->SetVariable(INSTALL_LOCATION, "near"); - ReleaseSingleInstanceMutex(); if (ShellExecuteNonBlocking("open", GetLauncherPathFilename(), GetSequencerSnapshot())) ExitProcess(0); // All done here - CreateSingleInstanceMutex(); + return "fail"; } return "ok"; @@ -584,9 +579,6 @@ SString CInstallManager::_PrepareLaunchLocation() { const bool isAdmin = IsUserAdmin(); - // Ensure GTA exe is not running - TerminateGTAIfRunning(); - const fs::path gtaDir = GetGameBaseDirectory(); const fs::path mtaDir = GetMTARootDirectory() / "MTA"; const fs::path launchDir = GetGameLaunchDirectory(); @@ -718,9 +710,6 @@ SString CInstallManager::_ProcessGtaPatchCheck() ////////////////////////////////////////////////////////// SString CInstallManager::_ProcessGtaDllCheck() { - // Ensure GTA exe is not running - TerminateGTAIfRunning(); - struct DependencyHash { const char* fileName; diff --git a/Client/loader/Main.cpp b/Client/loader/Main.cpp index adc5a93bae2..094b3e18b8a 100644 --- a/Client/loader/Main.cpp +++ b/Client/loader/Main.cpp @@ -93,9 +93,6 @@ MTAEXPORT int DoWinMain(HINSTANCE hLauncherInstance, HINSTANCE hPrevInstance, LP BsodDetectionPreLaunch(); MaybeShowCopySettingsDialog(); - // Make sure GTA is not running - HandleIfGTAIsAlreadyRunning(); - // Maybe warn user if no anti-virus running CheckAntiVirusStatus(); diff --git a/Client/loader/MainFunctions.cpp b/Client/loader/MainFunctions.cpp index ded6c37133c..5006ef46034 100644 --- a/Client/loader/MainFunctions.cpp +++ b/Client/loader/MainFunctions.cpp @@ -200,81 +200,38 @@ void HandleSpecialLaunchOptions() ////////////////////////////////////////////////////////// void HandleDuplicateLaunching() { - LPSTR lpCmdLine = GetCommandLine(); + LPWSTR szCommandLine = GetCommandLineW(); - int iRecheckTimeLimit = 2000; - while (!CreateSingleInstanceMutex()) - { - if (strcmp(lpCmdLine, "") != 0) - { - HWND hwMTAWindow = FindWindow(NULL, "MTA: San Andreas"); + if (!szCommandLine[0]) + return; + + HWND gameWindow = FindWindowA(nullptr, "MTA: San Andreas"); #ifdef MTA_DEBUG - if (hwMTAWindow == NULL) - hwMTAWindow = FindWindow(NULL, "MTA: San Andreas [DEBUG]"); + if (gameWindow == nullptr) + gameWindow = FindWindowA(nullptr, "MTA: San Andreas [DEBUG]"); #endif - if (hwMTAWindow != NULL) - { - LPWSTR szCommandLine = GetCommandLineW(); - int numArgs; - LPWSTR* aCommandLineArgs = CommandLineToArgvW(szCommandLine, &numArgs); - for (int i = 1; i < numArgs; ++i) - { - if (WStringX(aCommandLineArgs[i]).BeginsWith(L"mtasa://")) - { - WString wideConnectInfo = aCommandLineArgs[i]; - SString strConnectInfo = ToUTF8(wideConnectInfo); - COPYDATASTRUCT cdStruct; - cdStruct.cbData = strConnectInfo.length() + 1; - cdStruct.lpData = const_cast(strConnectInfo.c_str()); - cdStruct.dwData = URI_CONNECT; + if (gameWindow == nullptr) + return; - SendMessage(hwMTAWindow, WM_COPYDATA, NULL, (LPARAM)&cdStruct); - break; - } - } - } - else - { - if (iRecheckTimeLimit > 0) - { - // Sleep a little bit and check the mutex again - Sleep(500); - iRecheckTimeLimit -= 500; - continue; - } - SString strMessage; - strMessage += - _("Trouble restarting MTA:SA\n\n" - "If the problem persists, open Task Manager and\n" - "stop the 'gta_sa.exe' and 'Multi Theft Auto.exe' processes\n\n\n" - "Try to launch MTA:SA again?"); - if (MessageBoxUTF8(0, strMessage, _("Error") + _E("CL04"), MB_ICONWARNING | MB_YESNO | MB_TOPMOST) == - IDYES) // Trouble restarting MTA:SA - { - TerminateGTAIfRunning(); - TerminateOtherMTAIfRunning(); - ShellExecuteNonBlocking("open", PathJoin(GetMTASAPath(), MTA_EXE_NAME), lpCmdLine); - } - return ExitProcess(EXIT_ERROR); - } - } - else + int numArgs; + LPWSTR* aCommandLineArgs = CommandLineToArgvW(szCommandLine, &numArgs); + + for (int i = 1; i < numArgs; ++i) + { + if (WStringX(aCommandLineArgs[i]).BeginsWith(L"mtasa://")) { - if (!IsGTARunning() && !IsOtherMTARunning()) - { - MessageBoxUTF8(0, _("Another instance of MTA is already running.\n\nIf this problem persists, please restart your computer"), - _("Error") + _E("CL05"), MB_ICONERROR | MB_TOPMOST); - } - else if (MessageBoxUTF8(0, _("Another instance of MTA is already running.\n\nDo you want to terminate it?"), _("Error") + _E("CL06"), - MB_ICONQUESTION | MB_YESNO | MB_TOPMOST) == IDYES) - { - TerminateGTAIfRunning(); - TerminateOtherMTAIfRunning(); - ShellExecuteNonBlocking("open", PathJoin(GetMTASAPath(), MTA_EXE_NAME), lpCmdLine); - } + WString wideConnectInfo = aCommandLineArgs[i]; + SString strConnectInfo = ToUTF8(wideConnectInfo); + + COPYDATASTRUCT cdStruct; + cdStruct.cbData = strConnectInfo.length() + 1; + cdStruct.lpData = const_cast(strConnectInfo.c_str()); + cdStruct.dwData = URI_CONNECT; + + SendMessage(gameWindow, WM_COPYDATA, NULL, (LPARAM)&cdStruct); + return ExitProcess(EXIT_ERROR); } - return ExitProcess(EXIT_ERROR); } } @@ -480,8 +437,6 @@ void HandleCustomStartMessage() ////////////////////////////////////////////////////////// void PreLaunchWatchDogs() { - assert(!CreateSingleInstanceMutex()); - // // "L0" is opened before the launch sequence and is closed if MTA shutsdown with no error // "L1" is opened before the launch sequence and is closed if GTA is succesfully started @@ -587,35 +542,6 @@ void PostRunWatchDogs(int iReturnCode) } } -////////////////////////////////////////////////////////// -// -// HandleIfGTAIsAlreadyRunning -// -// Check for and maybe stop a running GTA process -// -////////////////////////////////////////////////////////// -void HandleIfGTAIsAlreadyRunning() -{ - if (IsGTARunning()) - { - if (MessageBoxUTF8( - 0, _("An instance of GTA: San Andreas is already running. It needs to be terminated before MTA:SA can be started. Do you want to do that now?"), - _("Information") + _E("CL10"), MB_YESNO | MB_ICONQUESTION | MB_TOPMOST) == IDYES) - { - TerminateOtherMTAIfRunning(); - TerminateGTAIfRunning(); - if (IsGTARunning()) - { - MessageBoxUTF8(0, _("Unable to terminate GTA: San Andreas. If the problem persists, please restart your computer."), - _("Information") + _E("CL11"), MB_OK | MB_ICONERROR | MB_TOPMOST); - return ExitProcess(EXIT_ERROR); - } - } - else - return ExitProcess(EXIT_OK); - } -} - ////////////////////////////////////////////////////////// // // ValidateGTAPath @@ -844,7 +770,6 @@ void CheckDataFiles() { SString strMessage(_("Main file has an incorrect name (%s)"), *GetLaunchFilename()); int iResponse = MessageBoxUTF8(NULL, strMessage, _("Error") + _E("CL33"), MB_RETRYCANCEL | MB_ICONERROR | MB_TOPMOST); - ReleaseSingleInstanceMutex(); if (iResponse == IDRETRY) ShellExecuteNonBlocking("open", PathJoin(strMTASAPath, MTA_EXE_NAME)); return ExitProcess(EXIT_ERROR); @@ -1272,7 +1197,6 @@ int LaunchGame(SString strCmdLine) // // Cleanup and exit. CloseHandle(piLoadee.hProcess); - ReleaseSingleInstanceMutex(); // Success, maybe return dwExitCode; diff --git a/Client/loader/MainFunctions.h b/Client/loader/MainFunctions.h index e1fecc516a3..4483ab2f6eb 100644 --- a/Client/loader/MainFunctions.h +++ b/Client/loader/MainFunctions.h @@ -16,7 +16,6 @@ void HandleDuplicateLaunching(); void HandleCustomStartMessage(); void PreLaunchWatchDogs(); void PostRunWatchDogs(int iReturnCode); -void HandleIfGTAIsAlreadyRunning(); void ValidateGTAPath(); void CheckAntiVirusStatus(); void CheckDataFiles(); diff --git a/Client/loader/Utils.cpp b/Client/loader/Utils.cpp index 7dae8ce439d..57e881abffa 100644 --- a/Client/loader/Utils.cpp +++ b/Client/loader/Utils.cpp @@ -29,7 +29,6 @@ namespace fs = std::filesystem; static SString g_strMTASAPath; static SString g_strGTAPath; -static HANDLE g_hMutex = NULL; static HMODULE hLibraryModule = NULL; HINSTANCE g_hInstance = NULL; @@ -312,18 +311,6 @@ std::vector GetGTAProcessList() return result; } -/////////////////////////////////////////////////////////////////////////// -// -// IsGTARunning -// -// -// -/////////////////////////////////////////////////////////////////////////// -bool IsGTARunning() -{ - return !GetGTAProcessList().empty(); -} - /////////////////////////////////////////////////////////////////////////// // // TerminateGTAIfRunning @@ -677,60 +664,6 @@ bool HasGTAPath() return false; } -/////////////////////////////////////////////////////////////// -// -// GetPEFileOffsets -// -// Get some commonly used file offsets -// -/////////////////////////////////////////////////////////////// -void GetPEFileOffsets(SPEFileOffsets& outOffsets, const SString& strGTAEXEPath) -{ - outOffsets = {0}; - long NtHeaders = 0; - ReadFileValue(strGTAEXEPath, NtHeaders, offsetof(IMAGE_DOS_HEADER, e_lfanew)); - outOffsets.TimeDateStamp = NtHeaders + offsetof(IMAGE_NT_HEADERS, FileHeader.TimeDateStamp); - outOffsets.Characteristics = NtHeaders + offsetof(IMAGE_NT_HEADERS, FileHeader.Characteristics); - outOffsets.AddressOfEntryPoint = NtHeaders + offsetof(IMAGE_NT_HEADERS, OptionalHeader.AddressOfEntryPoint); - outOffsets.DllCharacteristics = NtHeaders + offsetof(IMAGE_NT_HEADERS, OptionalHeader.DllCharacteristics); - - ushort usSizeOfOptionalHeader = 0; - ReadFileValue(strGTAEXEPath, usSizeOfOptionalHeader, NtHeaders + offsetof(IMAGE_NT_HEADERS, FileHeader.SizeOfOptionalHeader)); - ReadFileValue(strGTAEXEPath, outOffsets.sections[0].PointerToRawData, - NtHeaders + offsetof(IMAGE_NT_HEADERS, OptionalHeader) + usSizeOfOptionalHeader + offsetof(IMAGE_SECTION_HEADER, PointerToRawData)); -} - -/////////////////////////////////////////////////////////////// -// -// GetGtaFileVersion -// -// Hardcoded numbers used: -// 0x44 - File offset 0x44 is zero in legacy DOS stub. Encrypted exe does not have this. -// 0x347ADD is the section offset equivalent of 0x748ADD as used in CGameSA::FindGameVersion -// 0x53FF and 0x840F are also used in CGameSA::FindGameVersion -// -/////////////////////////////////////////////////////////////// -EGtaFileVersion GetGtaFileVersion(const SString& strGTAEXEPath) -{ - SPEFileOffsets fileOffsets; - GetPEFileOffsets(fileOffsets, strGTAEXEPath); - - char bIsEncypted = false; - ushort usIdBytes = 0; - ReadFileValue(strGTAEXEPath, bIsEncypted, 0x44); - ReadFileValue(strGTAEXEPath, usIdBytes, 0x347ADD + fileOffsets.sections[0].PointerToRawData); - - EGtaFileVersion versionType = EGtaFileVersion::Unknown; - if (usIdBytes == 0x53FF) - versionType = EGtaFileVersion::US; - else if (usIdBytes == 0x840F) - versionType = EGtaFileVersion::EU; - else if (bIsEncypted) - versionType = EGtaFileVersion::Encrypted; - - return versionType; -} - /////////////////////////////////////////////////////////////// // // FindFilesRecursive @@ -820,27 +753,6 @@ void FindRelevantFiles(const SString& strPath, std::vector& outFilePath } } -/////////////////////////////////////////////////////////////// -// -// MakeRandomIndexList -// -// Create a list of randomlu ordered indices from 0 to Size-1 -// -/////////////////////////////////////////////////////////////// -void MakeRandomIndexList(int Size, std::vector& outList) -{ - for (int i = 0; i < Size; i++) - outList.push_back(i); - - for (int i = 0; i < Size; i++) - { - int otherIdx = rand() % Size; - int Temp = outList[i]; - outList[i] = outList[otherIdx]; - outList[otherIdx] = Temp; - } -} - /////////////////////////////////////////////////////////////// // // GetOSVersion @@ -964,7 +876,6 @@ void RelaunchAsAdmin(const SString& strCmdLine, const SString& strReason) AddReportLog(7115, SString("Loader - Request to elevate privileges (%s)", *strReason)); MessageBoxUTF8(NULL, SString(_("MTA:SA needs Administrator access for the following task:\n\n '%s'\n\nPlease confirm in the next window."), *strReason), "Multi Theft Auto: San Andreas", MB_OK | MB_ICONINFORMATION | MB_TOPMOST); - ReleaseSingleInstanceMutex(); ShellExecuteNonBlocking("runas", PathJoin(GetMTASAPath(), MTA_EXE_NAME), strCmdLine); } @@ -1180,42 +1091,6 @@ bool TerminateProcess(DWORD dwProcessID, uint uiExitCode) return success; } -/////////////////////////////////////////////////////////////////////////// -// -// CreateSingleInstanceMutex -// -// -// -/////////////////////////////////////////////////////////////////////////// -bool CreateSingleInstanceMutex() -{ - HANDLE hMutex = CreateMutex(NULL, FALSE, TEXT(MTA_GUID)); - - if (GetLastError() == ERROR_ALREADY_EXISTS) - { - if (hMutex) - CloseHandle(hMutex); - return false; - } - assert(!g_hMutex); - g_hMutex = hMutex; - return true; -} - -/////////////////////////////////////////////////////////////////////////// -// -// ReleaseSingleInstanceMutex -// -// -// -/////////////////////////////////////////////////////////////////////////// -void ReleaseSingleInstanceMutex() -{ - // assert(g_hMutex); - CloseHandle(g_hMutex); - g_hMutex = NULL; -} - /////////////////////////////////////////////////////////////////////////// // // WaitForObject diff --git a/Client/loader/Utils.h b/Client/loader/Utils.h index be0685a83cc..d3532703a19 100644 --- a/Client/loader/Utils.h +++ b/Client/loader/Utils.h @@ -65,7 +65,6 @@ struct SPEFileOffsets }; void TerminateGTAIfRunning(); -bool IsGTARunning(); void TerminateOtherMTAIfRunning(); bool IsOtherMTARunning(); @@ -84,8 +83,6 @@ SString GetMTASAPath(); ePathResult DiscoverGTAPath(bool bFindIfMissing); SString GetGTAPath(); bool HasGTAPath(); -EGtaFileVersion GetGtaFileVersion(const SString& strGTAEXEPath); -void GetPEFileOffsets(SPEFileOffsets& outOffsets, const SString& strGTAEXEPath); void FindFilesRecursive(const SString& strPathMatch, std::vector& outFileList, uint uiMaxDepth = 99); SOSVersionInfo GetOSVersion(); @@ -100,9 +97,6 @@ void UpdateMTAVersionApplicationSetting(bool bQuiet = false); bool Is32bitProcess(DWORD processID); bool TerminateProcess(DWORD dwProcessID, uint uiExitCode = 0); -bool CreateSingleInstanceMutex(); -void ReleaseSingleInstanceMutex(); - void CleanDownloadCache(); HMODULE GetLibraryHandle(const SString& strFilename, DWORD* pdwOutLastError = NULL); diff --git a/Shared/data/MTA San Andreas/MTA/locale/en_US/client.pot b/Shared/data/MTA San Andreas/MTA/locale/en_US/client.pot index 268afcb67a7..9f737d8d4f9 100644 --- a/Shared/data/MTA San Andreas/MTA/locale/en_US/client.pot +++ b/Shared/data/MTA San Andreas/MTA/locale/en_US/client.pot @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: MTA San Andreas 1.x\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2025-06-16 19:16+0000\n" +"POT-Creation-Date: 2025-06-22 17:30+0000\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -61,15 +61,14 @@ msgstr "" #: Client/core/CConnectManager.cpp:422 Client/core/CConnectManager.cpp:432 #: Client/core/CSettings.cpp:2987 Client/core/CSettings.cpp:4281 #: Client/core/CSettings.cpp:4309 Client/core/CSettings.cpp:4920 -#: Client/core/CCore.cpp:1262 Client/core/CGUI.cpp:93 +#: Client/core/CCore.cpp:1277 Client/core/CGUI.cpp:93 #: Client/core/ServerBrowser/CServerBrowser.cpp:1261 #: Client/core/ServerBrowser/CServerBrowser.cpp:1283 #: Client/core/ServerBrowser/CServerBrowser.cpp:1340 #: Client/core/ServerBrowser/CServerBrowser.cpp:1389 #: Client/core/DXHook/CDirect3DHook9.cpp:127 -#: Client/loader/MainFunctions.cpp:252 Client/loader/MainFunctions.cpp:267 -#: Client/loader/MainFunctions.cpp:269 Client/loader/MainFunctions.cpp:846 -#: Client/loader/CInstallManager.cpp:552 Client/loader/CInstallManager.cpp:561 +#: Client/loader/MainFunctions.cpp:772 Client/loader/CInstallManager.cpp:547 +#: Client/loader/CInstallManager.cpp:556 #: Client/mods/deathmatch/logic/CClientGame.cpp:649 #: Client/mods/deathmatch/logic/CClientGame.cpp:723 #: Client/mods/deathmatch/logic/CClientGame.cpp:747 @@ -693,7 +692,7 @@ msgid "DPI aware" msgstr "" #: Client/core/CSettings.cpp:686 Client/core/CSettings.cpp:1032 -#: Client/loader/MainFunctions.cpp:389 +#: Client/loader/MainFunctions.cpp:346 msgid "Fullscreen mode:" msgstr "" @@ -702,7 +701,7 @@ msgid "Standard" msgstr "" #: Client/core/CSettings.cpp:694 Client/core/CSettings.cpp:1654 -#: Client/loader/MainFunctions.cpp:389 +#: Client/loader/MainFunctions.cpp:346 msgid "Borderless window" msgstr "" @@ -1530,7 +1529,7 @@ msgstr "" msgid "Visit latest news article" msgstr "" -#: Client/core/CCore.cpp:807 Client/loader/CInstallManager.cpp:1057 +#: Client/core/CCore.cpp:807 Client/loader/CInstallManager.cpp:1046 #, c-format msgid "MTA:SA cannot continue because drive %s does not have enough space." msgstr "" @@ -1539,106 +1538,106 @@ msgstr "" msgid "Fatal error" msgstr "" -#: Client/core/CCore.cpp:930 +#: Client/core/CCore.cpp:945 msgid "TO FIX, REMOVE THIS FILE:" msgstr "" -#: Client/core/CCore.cpp:962 +#: Client/core/CCore.cpp:977 #, c-format msgid "%s module is incorrect!" msgstr "" -#: Client/core/CCore.cpp:1262 +#: Client/core/CCore.cpp:1277 msgid "Error executing URL" msgstr "" #. m_pCommands->Add ( "e", CCommandFuncs::Editor ); #. m_pCommands->Add ( "clear", CCommandFuncs::Clear ); -#: Client/core/CCore.cpp:1356 +#: Client/core/CCore.cpp:1371 msgid "this help screen" msgstr "" -#: Client/core/CCore.cpp:1357 Client/core/CCore.cpp:1358 +#: Client/core/CCore.cpp:1372 Client/core/CCore.cpp:1373 msgid "exits the application" msgstr "" -#: Client/core/CCore.cpp:1359 +#: Client/core/CCore.cpp:1374 msgid "shows the version" msgstr "" -#: Client/core/CCore.cpp:1360 +#: Client/core/CCore.cpp:1375 msgid "shows the time" msgstr "" -#: Client/core/CCore.cpp:1361 +#: Client/core/CCore.cpp:1376 msgid "shows the hud" msgstr "" -#: Client/core/CCore.cpp:1362 +#: Client/core/CCore.cpp:1377 msgid "shows all the binds" msgstr "" -#: Client/core/CCore.cpp:1363 +#: Client/core/CCore.cpp:1378 msgid "shows your serial" msgstr "" -#: Client/core/CCore.cpp:1372 +#: Client/core/CCore.cpp:1387 msgid "connects to a server (host port nick pass)" msgstr "" -#: Client/core/CCore.cpp:1373 +#: Client/core/CCore.cpp:1388 msgid "connects to a previous server" msgstr "" -#: Client/core/CCore.cpp:1374 +#: Client/core/CCore.cpp:1389 msgid "binds a key (key control)" msgstr "" -#: Client/core/CCore.cpp:1375 +#: Client/core/CCore.cpp:1390 msgid "unbinds a key (key)" msgstr "" -#: Client/core/CCore.cpp:1376 +#: Client/core/CCore.cpp:1391 msgid "copies the default gta controls" msgstr "" -#: Client/core/CCore.cpp:1377 +#: Client/core/CCore.cpp:1392 msgid "outputs a screenshot" msgstr "" -#: Client/core/CCore.cpp:1378 +#: Client/core/CCore.cpp:1393 msgid "immediately saves the config" msgstr "" -#: Client/core/CCore.cpp:1380 +#: Client/core/CCore.cpp:1395 msgid "clears the debug view" msgstr "" -#: Client/core/CCore.cpp:1381 +#: Client/core/CCore.cpp:1396 msgid "scrolls the chatbox upwards" msgstr "" -#: Client/core/CCore.cpp:1382 +#: Client/core/CCore.cpp:1397 msgid "scrolls the chatbox downwards" msgstr "" -#: Client/core/CCore.cpp:1383 +#: Client/core/CCore.cpp:1398 msgid "scrolls the debug view upwards" msgstr "" -#: Client/core/CCore.cpp:1384 +#: Client/core/CCore.cpp:1399 msgid "scrolls the debug view downwards" msgstr "" -#: Client/core/CCore.cpp:1387 +#: Client/core/CCore.cpp:1402 msgid "shows the memory statistics" msgstr "" -#: Client/core/CCore.cpp:1388 +#: Client/core/CCore.cpp:1403 msgid "shows the frame timing graph" msgstr "" -#: Client/core/CCore.cpp:1392 +#: Client/core/CCore.cpp:1407 msgid "for developers: reload news" msgstr "" @@ -2027,8 +2026,7 @@ msgstr "" #: Client/core/ServerBrowser/CServerBrowser.cpp:1363 #: Client/core/ServerBrowser/CServerInfo.cpp:319 -#: Client/loader/MainFunctions.cpp:603 Client/loader/MainFunctions.cpp:610 -#: Client/loader/MainFunctions.cpp:1219 Client/game_sa/CGameSA.cpp:269 +#: Client/loader/MainFunctions.cpp:1144 Client/game_sa/CGameSA.cpp:269 msgid "Information" msgstr "" @@ -2175,39 +2173,14 @@ msgid "" "latest Windows Service Packs are installed correctly." msgstr "" -#: Client/loader/MainFunctions.cpp:248 -msgid "" -"Trouble restarting MTA:SA\n" -"\n" -"If the problem persists, open Task Manager and\n" -"stop the 'gta_sa.exe' and 'Multi Theft Auto.exe' processes\n" -"\n" -"\n" -"Try to launch MTA:SA again?" -msgstr "" - -#: Client/loader/MainFunctions.cpp:266 -msgid "" -"Another instance of MTA is already running.\n" -"\n" -"If this problem persists, please restart your computer" -msgstr "" - -#: Client/loader/MainFunctions.cpp:269 -msgid "" -"Another instance of MTA is already running.\n" -"\n" -"Do you want to terminate it?" -msgstr "" - -#: Client/loader/MainFunctions.cpp:294 +#: Client/loader/MainFunctions.cpp:251 msgid "" "Are you having problems running MTA:SA?.\n" "\n" "Do you want to revert to an earlier version?" msgstr "" -#: Client/loader/MainFunctions.cpp:324 +#: Client/loader/MainFunctions.cpp:281 msgid "" "There seems to be a problem launching MTA:SA.\n" "Resetting GTA settings can sometimes fix this problem.\n" @@ -2215,20 +2188,20 @@ msgid "" "Do you want to reset GTA settings now?" msgstr "" -#: Client/loader/MainFunctions.cpp:339 +#: Client/loader/MainFunctions.cpp:296 msgid "" "GTA settings have been reset.\n" "\n" "Press OK to continue." msgstr "" -#: Client/loader/MainFunctions.cpp:344 +#: Client/loader/MainFunctions.cpp:301 #, c-format msgid "File could not be deleted: '%s'" msgstr "" #. No settings to delete, or can't find them -#: Client/loader/MainFunctions.cpp:352 +#: Client/loader/MainFunctions.cpp:309 msgid "" "Are you having problems running MTA:SA?.\n" "\n" @@ -2236,21 +2209,21 @@ msgid "" msgstr "" #. Inform user -#: Client/loader/MainFunctions.cpp:388 +#: Client/loader/MainFunctions.cpp:345 msgid "" "Are you having problems running MTA:SA?.\n" "\n" "Do you want to change the following setting?" msgstr "" -#: Client/loader/MainFunctions.cpp:431 +#: Client/loader/MainFunctions.cpp:388 msgid "" "Are you having problems running MTA:SA?.\n" "\n" "Try disabling the following products for GTA and MTA:" msgstr "" -#: Client/loader/MainFunctions.cpp:465 +#: Client/loader/MainFunctions.cpp:422 msgid "" "WARNING\n" "\n" @@ -2259,29 +2232,17 @@ msgid "" "\n" msgstr "" -#: Client/loader/MainFunctions.cpp:468 +#: Client/loader/MainFunctions.cpp:425 #, c-format msgid "The detected file was: %s\n" msgstr "" -#: Client/loader/MainFunctions.cpp:602 -msgid "" -"An instance of GTA: San Andreas is already running. It needs to be " -"terminated before MTA:SA can be started. Do you want to do that now?" -msgstr "" - -#: Client/loader/MainFunctions.cpp:609 -msgid "" -"Unable to terminate GTA: San Andreas. If the problem persists, please " -"restart your computer." -msgstr "" - -#: Client/loader/MainFunctions.cpp:632 +#: Client/loader/MainFunctions.cpp:558 msgid "" "Registry entries are missing. Please reinstall Multi Theft Auto: San Andreas." msgstr "" -#: Client/loader/MainFunctions.cpp:638 +#: Client/loader/MainFunctions.cpp:564 msgid "" "The path to your installation of GTA: San Andreas contains unsupported " "(unicode) characters. Please move your Grand Theft Auto: San Andreas " @@ -2289,7 +2250,7 @@ msgid "" "characters and reinstall Multi Theft Auto: San Andreas." msgstr "" -#: Client/loader/MainFunctions.cpp:648 +#: Client/loader/MainFunctions.cpp:574 msgid "" "The path to your installation of 'MTA:SA' or 'GTA: San Andreas'\n" "contains a ';' (semicolon).\n" @@ -2298,41 +2259,41 @@ msgid "" " move your installation(s) to a path that does not contain a semicolon." msgstr "" -#: Client/loader/MainFunctions.cpp:810 +#: Client/loader/MainFunctions.cpp:736 msgid "" "Load failed. Please ensure that the latest data files have been installed " "correctly." msgstr "" -#: Client/loader/MainFunctions.cpp:819 +#: Client/loader/MainFunctions.cpp:745 #, c-format msgid "Load failed. Please ensure that %s is installed correctly." msgstr "" -#: Client/loader/MainFunctions.cpp:826 +#: Client/loader/MainFunctions.cpp:752 #, c-format msgid "Load failed. Could not find gta_sa.exe in %s." msgstr "" -#: Client/loader/MainFunctions.cpp:836 +#: Client/loader/MainFunctions.cpp:762 #, c-format msgid "" "Load failed. %s exists in the GTA directory. Please delete before continuing." msgstr "" -#: Client/loader/MainFunctions.cpp:845 +#: Client/loader/MainFunctions.cpp:771 #, c-format msgid "Main file has an incorrect name (%s)" msgstr "" -#: Client/loader/MainFunctions.cpp:856 +#: Client/loader/MainFunctions.cpp:781 msgid "" "Main file is unsigned. Possible virus activity.\n" "\n" "See online help if MTA does not work correctly." msgstr "" -#: Client/loader/MainFunctions.cpp:882 +#: Client/loader/MainFunctions.cpp:807 #, c-format msgid "" "Data file %s is missing. Possible virus activity.\n" @@ -2341,7 +2302,7 @@ msgid "" "See online help if MTA does not work correctly." msgstr "" -#: Client/loader/MainFunctions.cpp:893 +#: Client/loader/MainFunctions.cpp:818 #, c-format msgid "" "Data file %s is modified. Possible virus activity.\n" @@ -2350,7 +2311,7 @@ msgid "" "See online help if MTA does not work correctly." msgstr "" -#: Client/loader/MainFunctions.cpp:907 +#: Client/loader/MainFunctions.cpp:832 msgid "" ".asi files are in the 'MTA:SA' or 'GTA: San Andreas' installation " "directory.\n" @@ -2358,32 +2319,32 @@ msgid "" "Remove these .asi files if you experience problems with MTA:SA." msgstr "" -#: Client/loader/MainFunctions.cpp:1009 +#: Client/loader/MainFunctions.cpp:934 msgid "" "File version mismatch error. Reinstall MTA:SA if you experience problems.\n" msgstr "" -#: Client/loader/MainFunctions.cpp:1018 +#: Client/loader/MainFunctions.cpp:943 msgid "Some files are missing. Reinstall MTA:SA if you experience problems.\n" msgstr "" -#: Client/loader/MainFunctions.cpp:1030 +#: Client/loader/MainFunctions.cpp:955 msgid "" "MTA:SA is not compatible with Windows 'Safe Mode'.\n" "\n" "Please restart your PC.\n" msgstr "" -#: Client/loader/MainFunctions.cpp:1123 +#: Client/loader/MainFunctions.cpp:1048 msgid "Fix configuration issue" msgstr "" #. Try to relaunch as admin if not done so already -#: Client/loader/MainFunctions.cpp:1157 +#: Client/loader/MainFunctions.cpp:1082 msgid "Fix elevation required error" msgstr "" -#: Client/loader/MainFunctions.cpp:1164 +#: Client/loader/MainFunctions.cpp:1089 #, c-format msgid "" "Could not start Grand Theft Auto: San Andreas. Please try restarting, or if " @@ -2392,34 +2353,34 @@ msgid "" "[%s]" msgstr "" -#: Client/loader/MainFunctions.cpp:1219 +#: Client/loader/MainFunctions.cpp:1144 msgid "" "GTA: San Andreas may not have launched correctly. Do you want to terminate " "it?" msgstr "" -#: Client/loader/Utils.cpp:535 +#: Client/loader/Utils.cpp:522 msgid "" "Start Grand Theft Auto: San Andreas.\n" "Ensure the game is placed in the 'Program Files (x86)' folder." msgstr "" -#: Client/loader/Utils.cpp:535 Client/loader/Utils.cpp:548 +#: Client/loader/Utils.cpp:522 Client/loader/Utils.cpp:535 msgid "Searching for GTA: San Andreas" msgstr "" -#: Client/loader/Utils.cpp:548 +#: Client/loader/Utils.cpp:535 msgid "" "Sorry, game not found.\n" "Start Grand Theft Auto: San Andreas and click retry.\n" "Ensure the game is placed in the 'Program Files (x86)' folder." msgstr "" -#: Client/loader/Utils.cpp:597 +#: Client/loader/Utils.cpp:584 msgid "Select your Grand Theft Auto: San Andreas Installation Directory" msgstr "" -#: Client/loader/Utils.cpp:965 Client/loader/CInstallManager.cpp:361 +#: Client/loader/Utils.cpp:877 Client/loader/CInstallManager.cpp:361 #, c-format msgid "" "MTA:SA needs Administrator access for the following task:\n" @@ -2429,28 +2390,28 @@ msgid "" "Please confirm in the next window." msgstr "" -#: Client/loader/Utils.cpp:1066 +#: Client/loader/Utils.cpp:977 #, c-format msgid "Error loading %s module! (%s)" msgstr "" -#: Client/loader/Utils.cpp:1391 Client/loader/Dialogs.cpp:702 +#: Client/loader/Utils.cpp:1266 Client/loader/Dialogs.cpp:702 msgid "Copying files..." msgstr "" -#: Client/loader/Utils.cpp:1451 Client/loader/Dialogs.cpp:707 +#: Client/loader/Utils.cpp:1326 Client/loader/Dialogs.cpp:707 msgid "Copy finished early. Everything OK." msgstr "" -#: Client/loader/Utils.cpp:1457 Client/loader/Dialogs.cpp:712 +#: Client/loader/Utils.cpp:1332 Client/loader/Dialogs.cpp:712 msgid "Finishing..." msgstr "" -#: Client/loader/Utils.cpp:1459 Client/loader/Dialogs.cpp:716 +#: Client/loader/Utils.cpp:1334 Client/loader/Dialogs.cpp:716 msgid "Done!" msgstr "" -#: Client/loader/Utils.cpp:1499 +#: Client/loader/Utils.cpp:1374 #, c-format msgid "" "New installation of %s detected.\n" @@ -2458,42 +2419,42 @@ msgid "" "Do you want to copy your settings from %s ?" msgstr "" -#: Client/loader/Utils.cpp:1538 +#: Client/loader/Utils.cpp:1413 #, c-format msgid "GTA:SA had trouble opening the file '%s'" msgstr "" -#: Client/loader/Utils.cpp:1560 +#: Client/loader/Utils.cpp:1435 #, c-format msgid "GTA:SA is missing the file '%s'." msgstr "" -#: Client/loader/Utils.cpp:1585 +#: Client/loader/Utils.cpp:1460 msgid "GTA:SA had trouble loading a model." msgstr "" -#: Client/loader/Utils.cpp:1587 +#: Client/loader/Utils.cpp:1462 msgid "If you recently modified gta3.img, then try reinstalling GTA:SA." msgstr "" -#: Client/loader/Utils.cpp:1612 +#: Client/loader/Utils.cpp:1487 msgid "GTA:SA had trouble adding an upgrade to a vehicle." msgstr "" -#: Client/loader/Utils.cpp:1631 +#: Client/loader/Utils.cpp:1506 #, c-format msgid "GTA:SA found errors in the file '%s'" msgstr "" -#: Client/loader/Utils.cpp:1713 +#: Client/loader/Utils.cpp:1588 msgid "Did your computer restart when playing MTA:SA?" msgstr "" -#: Client/loader/Utils.cpp:1778 +#: Client/loader/Utils.cpp:1653 msgid "Please terminate the following programs before continuing:" msgstr "" -#: Client/loader/CInstallManager.cpp:376 +#: Client/loader/CInstallManager.cpp:373 #, c-format msgid "" "MTA:SA could not complete the following task:\n" @@ -2501,92 +2462,92 @@ msgid "" " '%s'\n" msgstr "" -#: Client/loader/CInstallManager.cpp:426 +#: Client/loader/CInstallManager.cpp:423 msgid "" "** The crash was caused by a graphics driver error **\n" "\n" "** Please update your graphics drivers **" msgstr "" -#: Client/loader/CInstallManager.cpp:532 +#: Client/loader/CInstallManager.cpp:527 msgid "Install updated MTA:SA files" msgstr "" -#: Client/loader/CInstallManager.cpp:552 +#: Client/loader/CInstallManager.cpp:547 msgid "" "Could not update due to file conflicts. Please close other applications and " "retry" msgstr "" -#: Client/loader/CInstallManager.cpp:561 +#: Client/loader/CInstallManager.cpp:556 #, c-format msgid "Multi Theft Auto has not been installed properly, please reinstall. %s" msgstr "" -#: Client/loader/CInstallManager.cpp:613 +#: Client/loader/CInstallManager.cpp:605 msgid "Create GTA:SA junctions" msgstr "" -#: Client/loader/CInstallManager.cpp:657 +#: Client/loader/CInstallManager.cpp:649 msgid "MTA:SA cannot launch because copying a file failed:" msgstr "" -#: Client/loader/CInstallManager.cpp:663 Client/loader/CInstallManager.cpp:703 +#: Client/loader/CInstallManager.cpp:655 Client/loader/CInstallManager.cpp:695 msgid "MTA:SA cannot launch because an MTA:SA file is incorrect or missing:" msgstr "" -#: Client/loader/CInstallManager.cpp:672 +#: Client/loader/CInstallManager.cpp:664 msgid "Copy MTA:SA files" msgstr "" -#: Client/loader/CInstallManager.cpp:695 Client/loader/CInstallManager.cpp:773 +#: Client/loader/CInstallManager.cpp:687 Client/loader/CInstallManager.cpp:762 msgid "MTA:SA cannot launch because a GTA:SA file is incorrect or missing:" msgstr "" -#: Client/loader/CInstallManager.cpp:780 +#: Client/loader/CInstallManager.cpp:769 msgid "Patch GTA:SA dependency" msgstr "" -#: Client/loader/CInstallManager.cpp:828 +#: Client/loader/CInstallManager.cpp:817 msgid "" "MTA:SA cannot launch because the GTA:SA executable is incorrect or missing:" msgstr "" -#: Client/loader/CInstallManager.cpp:832 +#: Client/loader/CInstallManager.cpp:821 msgid "" "Please check your anti-virus for a false-positive detection, try to add an " "exception for the GTA:SA executable and restart MTA:SA." msgstr "" -#: Client/loader/CInstallManager.cpp:838 +#: Client/loader/CInstallManager.cpp:827 msgid "Generate GTA:SA" msgstr "" -#: Client/loader/CInstallManager.cpp:853 +#: Client/loader/CInstallManager.cpp:842 msgid "MTA:SA cannot launch because the GTA:SA executable is not loadable:" msgstr "" -#: Client/loader/CInstallManager.cpp:860 Client/loader/CInstallManager.cpp:883 +#: Client/loader/CInstallManager.cpp:849 Client/loader/CInstallManager.cpp:872 msgid "Patch GTA:SA" msgstr "" -#: Client/loader/CInstallManager.cpp:876 +#: Client/loader/CInstallManager.cpp:865 msgid "MTA:SA cannot launch because patching GTA:SA has failed:" msgstr "" -#: Client/loader/CInstallManager.cpp:1113 +#: Client/loader/CInstallManager.cpp:1102 msgid "Missing file:" msgstr "" -#: Client/loader/CInstallManager.cpp:1117 +#: Client/loader/CInstallManager.cpp:1106 msgid "If MTA fails to load, please re-install GTA:SA" msgstr "" -#: Client/loader/CInstallManager.cpp:1152 +#: Client/loader/CInstallManager.cpp:1141 msgid "Update install settings" msgstr "" -#: Client/loader/CInstallManager.cpp:1305 +#: Client/loader/CInstallManager.cpp:1294 msgid "Update compatibility settings" msgstr ""