@@ -655,13 +655,13 @@ SString CInstallManager::_PrepareLaunchLocation()
655655 if (fs::is_regular_file (sourcePath, ec))
656656 {
657657 SString strMessage (_ (" MTA:SA cannot launch because copying a file failed:" ));
658- strMessage += " \n\n " + targetPath.string ( );
658+ strMessage += " \n\n " + ToUTF8 ( targetPath.wstring () );
659659 BrowseToSolution (" copy-files" , ASK_GO_ONLINE, strMessage);
660660 }
661661 else
662662 {
663663 SString strMessage (_ (" MTA:SA cannot launch because an MTA:SA file is incorrect or missing:" ));
664- strMessage += " \n\n " + sourcePath.string ( );
664+ strMessage += " \n\n " + ToUTF8 ( sourcePath.wstring () );
665665 BrowseToSolution (" mta-datafiles-missing" , ASK_GO_ONLINE, strMessage);
666666 }
667667
@@ -693,15 +693,15 @@ SString CInstallManager::_ProcessGtaPatchCheck()
693693 if (!FileGenerator::IsPatchBase (patchBasePath))
694694 {
695695 SString strMessage (_ (" MTA:SA cannot launch because a GTA:SA file is incorrect or missing:" ));
696- strMessage += " \n\n " + patchBasePath.string ( );
696+ strMessage += " \n\n " + ToUTF8 ( patchBasePath.wstring () );
697697 BrowseToSolution (" gengta_pakfiles" , ASK_GO_ONLINE, strMessage);
698698 return " quit" ;
699699 }
700700
701701 if (!FileGenerator::IsPatchDiff (patchDiffPath))
702702 {
703703 SString strMessage (_ (" MTA:SA cannot launch because an MTA:SA file is incorrect or missing:" ));
704- strMessage += " \n\n " + patchDiffPath.string ( );
704+ strMessage += " \n\n " + ToUTF8 ( patchDiffPath.wstring () );
705705 BrowseToSolution (" mta-datafiles-missing" , ASK_GO_ONLINE, strMessage);
706706 return " quit" ;
707707 }
@@ -771,7 +771,7 @@ SString CInstallManager::_ProcessGtaDllCheck()
771771 if (isAdmin)
772772 {
773773 SString strMessage (_ (" MTA:SA cannot launch because a GTA:SA file is incorrect or missing:" ));
774- strMessage += " \n\n " + dependecyPath.string ( );
774+ strMessage += " \n\n " + ToUTF8 ( dependecyPath.wstring () );
775775 BrowseToSolution (SString (" gendep_error&name=%s" , dependency.fileName ), ASK_GO_ONLINE, strMessage);
776776 return " quit" ;
777777 }
@@ -826,7 +826,7 @@ SString CInstallManager::_ProcessGtaVersionCheck()
826826 if (isAdmin)
827827 {
828828 SString strMessage (_ (" MTA:SA cannot launch because the GTA:SA executable is incorrect or missing:" ));
829- strMessage += " \n\n " + gtaExePath.string ( );
829+ strMessage += " \n\n " + ToUTF8 ( gtaExePath.wstring () );
830830 strMessage +=
831831 " \n\n " +
832832 _ (" Please check your anti-virus for a false-positive detection, try to add an exception for the GTA:SA executable and restart MTA:SA." );
@@ -851,7 +851,7 @@ SString CInstallManager::_ProcessGtaVersionCheck()
851851 if (isAdmin)
852852 {
853853 SString strMessage (_ (" MTA:SA cannot launch because the GTA:SA executable is not loadable:" ));
854- strMessage += " \n\n " + gtaExePath.string ( );
854+ strMessage += " \n\n " + ToUTF8 ( gtaExePath.wstring () );
855855 BrowseToSolution (SString (" gengta_error&code=%d" , ec.value ()), ASK_GO_ONLINE, strMessage);
856856 return " quit" ;
857857 }
@@ -874,7 +874,7 @@ SString CInstallManager::_ProcessGtaVersionCheck()
874874 if (isAdmin)
875875 {
876876 SString strMessage (_ (" MTA:SA cannot launch because patching GTA:SA has failed:" ));
877- strMessage += " \n\n " + gtaExePath.string ( );
877+ strMessage += " \n\n " + ToUTF8 ( gtaExePath.wstring () );
878878 BrowseToSolution (SString (" patchgta_error&code=%d" , ec.value ()), ASK_GO_ONLINE, strMessage);
879879 return " quit" ;
880880 }
@@ -1275,7 +1275,8 @@ SString CInstallManager::_ProcessAppCompatChecks()
12751275 WString strUrlValue = ReadCompatibilityEntries (strUrlItem, strUrlKey, HKEY_CURRENT_USER, 0 );
12761276 if (!strUrlValue.empty ())
12771277 {
1278- WriteDebugEvent (SString (" GameUX ServiceLocation was '%s'" , *ToUTF8 (strUrlValue)));
1278+ WriteDebugEvent (std::format (" GameUX ServiceLocation was '{}'" , ToUTF8 (strUrlValue)));
1279+
12791280 if (strUrlValue.ContainsI (L" :" ))
12801281 {
12811282 strUrlValue = L" disabled" ; // Can be anything not containing `:`
0 commit comments