From 8930a72de2569c6445d36b4fd405b4c81ad3e07a Mon Sep 17 00:00:00 2001 From: AkiVer Date: Wed, 13 Jul 2022 19:06:34 +0200 Subject: [PATCH] feat: display message in case of error when launching csgo fix #561 --- Manager/MultilingualResources/Manager.ar.xlf | 22 ++++ Manager/MultilingualResources/Manager.da.xlf | 22 ++++ Manager/MultilingualResources/Manager.de.xlf | 22 ++++ Manager/MultilingualResources/Manager.es.xlf | 22 ++++ Manager/MultilingualResources/Manager.fr.xlf | 22 ++++ Manager/MultilingualResources/Manager.hr.xlf | 22 ++++ Manager/MultilingualResources/Manager.hu.xlf | 22 ++++ Manager/MultilingualResources/Manager.it.xlf | 22 ++++ Manager/MultilingualResources/Manager.ja.xlf | 22 ++++ Manager/MultilingualResources/Manager.nl.xlf | 22 ++++ Manager/MultilingualResources/Manager.pl.xlf | 22 ++++ .../MultilingualResources/Manager.pt-BR.xlf | 22 ++++ Manager/MultilingualResources/Manager.pt.xlf | 22 ++++ Manager/MultilingualResources/Manager.ru.xlf | 22 ++++ .../MultilingualResources/Manager.sr-Cyrl.xlf | 22 ++++ .../MultilingualResources/Manager.tr-TR.xlf | 22 ++++ Manager/MultilingualResources/Manager.tr.xlf | 22 ++++ .../MultilingualResources/Manager.zh-Hans.xlf | 22 ++++ .../MultilingualResources/Manager.zh-Hant.xlf | 22 ++++ Manager/Properties/Resources.Designer.cs | 39 +++++++ Manager/Properties/Resources.es.resx | 3 + Manager/Properties/Resources.fr.resx | 15 +++ Manager/Properties/Resources.hu.resx | 3 + Manager/Properties/Resources.pl.resx | 3 + Manager/Properties/Resources.pt-BR.resx | 3 + Manager/Properties/Resources.resx | 15 +++ Manager/Properties/Resources.zh-Hans.resx | 3 + Manager/Services/DialogService.cs | 8 -- Manager/Services/IDialogService.cs | 2 - .../ViewModel/Demos/DemoDetailsViewModel.cs | 85 +++++++-------- Manager/ViewModel/Demos/DemoListViewModel.cs | 83 +++++--------- Manager/ViewModel/Demos/DemoMovieViewModel.cs | 6 +- .../ViewModel/Demos/DemoStuffsViewModel.cs | 33 +++--- .../Players/PlayerDetailsViewModel.cs | 84 ++++++++------- .../ViewModel/Rounds/RoundDetailsViewModel.cs | 34 +++--- Manager/ViewModel/Shared/BaseViewModel.cs | 34 +++++- Services/Concrete/GameLauncher.cs | 101 ++++++++++++------ Services/Concrete/Movie/MovieService.cs | 2 +- Services/Exceptions/Launcher/HlaeNotFound.cs | 2 +- .../Exceptions/Launcher/KillCsgoException.cs | 11 ++ .../Exceptions/Launcher/KillHlaeException.cs | 11 ++ .../SteamExecutableNotFoundException.cs | 11 ++ .../MultilingualResources/Services.ar.xlf | 4 - .../MultilingualResources/Services.da.xlf | 4 - .../MultilingualResources/Services.de.xlf | 4 - .../MultilingualResources/Services.es.xlf | 4 - .../MultilingualResources/Services.fr.xlf | 4 - .../MultilingualResources/Services.hr.xlf | 4 - .../MultilingualResources/Services.hu.xlf | 4 - .../MultilingualResources/Services.it.xlf | 4 - .../MultilingualResources/Services.ja.xlf | 4 - .../MultilingualResources/Services.nl.xlf | 4 - .../MultilingualResources/Services.pl.xlf | 4 - .../MultilingualResources/Services.pt-BR.xlf | 4 - .../MultilingualResources/Services.pt.xlf | 4 - .../MultilingualResources/Services.ru.xlf | 4 - .../Services.sr-Cyrl.xlf | 4 - .../MultilingualResources/Services.tr-TR.xlf | 4 - .../MultilingualResources/Services.tr.xlf | 4 - .../Services.zh-Hans.xlf | 6 +- .../Services.zh-Hant.xlf | 4 - Services/Properties/Resources.Designer.cs | 11 +- Services/Properties/Resources.es.resx | 3 - Services/Properties/Resources.fr.resx | 3 - Services/Properties/Resources.hu.resx | 3 - Services/Properties/Resources.pl.resx | 3 - Services/Properties/Resources.pt-BR.resx | 3 - Services/Properties/Resources.resx | 3 - Services/Properties/Resources.zh-Hans.resx | 3 - Services/Services.csproj | 3 + 70 files changed, 791 insertions(+), 331 deletions(-) create mode 100644 Services/Exceptions/Launcher/KillCsgoException.cs create mode 100644 Services/Exceptions/Launcher/KillHlaeException.cs create mode 100644 Services/Exceptions/Launcher/SteamExecutableNotFoundException.cs diff --git a/Manager/MultilingualResources/Manager.ar.xlf b/Manager/MultilingualResources/Manager.ar.xlf index 817e18e81..4b473eecc 100644 --- a/Manager/MultilingualResources/Manager.ar.xlf +++ b/Manager/MultilingualResources/Manager.ar.xlf @@ -4235,6 +4235,28 @@ Please update it by clicking on the "Update" button. The path contains non-basic latin characters which may lead to unexpected behaviors in-game. Please select a folder that contains only 7-bit ASCII characters. The path contains non-basic latin characters which may lead to unexpected behaviors in-game. Please select a folder that contains only 7-bit ASCII characters. + + HLAE not found. Please install it by enabling it from settings. + HLAE not found. Please install it by enabling it from settings. + + + Failed to close CSGO, please do it manually and try again. +Error: {0}. + Failed to close CSGO, please do it manually and try again. +Error: {0}. + + + Failed to close HLAE, please do it manually and try again. +Error: {0}. + Failed to close HLAE, please do it manually and try again. +Error: {0}. + + + Failed to start CSGO. +Error: {0}. + Failed to start CSGO. +Error: {0}. + diff --git a/Manager/MultilingualResources/Manager.da.xlf b/Manager/MultilingualResources/Manager.da.xlf index f30d88729..56bac88bc 100644 --- a/Manager/MultilingualResources/Manager.da.xlf +++ b/Manager/MultilingualResources/Manager.da.xlf @@ -4236,6 +4236,28 @@ Please update it by clicking on the "Update" button. The path contains non-basic latin characters which may lead to unexpected behaviors in-game. Please select a folder that contains only 7-bit ASCII characters. The path contains non-basic latin characters which may lead to unexpected behaviors in-game. Please select a folder that contains only 7-bit ASCII characters. + + HLAE not found. Please install it by enabling it from settings. + HLAE not found. Please install it by enabling it from settings. + + + Failed to close CSGO, please do it manually and try again. +Error: {0}. + Failed to close CSGO, please do it manually and try again. +Error: {0}. + + + Failed to close HLAE, please do it manually and try again. +Error: {0}. + Failed to close HLAE, please do it manually and try again. +Error: {0}. + + + Failed to start CSGO. +Error: {0}. + Failed to start CSGO. +Error: {0}. + diff --git a/Manager/MultilingualResources/Manager.de.xlf b/Manager/MultilingualResources/Manager.de.xlf index 6041b534d..171889977 100644 --- a/Manager/MultilingualResources/Manager.de.xlf +++ b/Manager/MultilingualResources/Manager.de.xlf @@ -4236,6 +4236,28 @@ Bitte aktualisieren Sie mit dem Klicken auf den "Update"-Button. The path contains non-basic latin characters which may lead to unexpected behaviors in-game. Please select a folder that contains only 7-bit ASCII characters. The path contains non-basic latin characters which may lead to unexpected behaviors in-game. Please select a folder that contains only 7-bit ASCII characters. + + HLAE not found. Please install it by enabling it from settings. + HLAE not found. Please install it by enabling it from settings. + + + Failed to close CSGO, please do it manually and try again. +Error: {0}. + Failed to close CSGO, please do it manually and try again. +Error: {0}. + + + Failed to close HLAE, please do it manually and try again. +Error: {0}. + Failed to close HLAE, please do it manually and try again. +Error: {0}. + + + Failed to start CSGO. +Error: {0}. + Failed to start CSGO. +Error: {0}. + diff --git a/Manager/MultilingualResources/Manager.es.xlf b/Manager/MultilingualResources/Manager.es.xlf index 5521bf7d7..82451e7da 100644 --- a/Manager/MultilingualResources/Manager.es.xlf +++ b/Manager/MultilingualResources/Manager.es.xlf @@ -4253,6 +4253,28 @@ Please update it by clicking on the "Update" button. The path contains non-basic latin characters which may lead to unexpected behaviors in-game. Please select a folder that contains only 7-bit ASCII characters. The path contains non-basic latin characters which may lead to unexpected behaviors in-game. Please select a folder that contains only 7-bit ASCII characters. + + HLAE not found. Please install it by enabling it from settings. + HLAE no encontrado. Por favor instálalo activándolo desde la configuración. + + + Failed to close CSGO, please do it manually and try again. +Error: {0}. + Failed to close CSGO, please do it manually and try again. +Error: {0}. + + + Failed to close HLAE, please do it manually and try again. +Error: {0}. + Failed to close HLAE, please do it manually and try again. +Error: {0}. + + + Failed to start CSGO. +Error: {0}. + Failed to start CSGO. +Error: {0}. + diff --git a/Manager/MultilingualResources/Manager.fr.xlf b/Manager/MultilingualResources/Manager.fr.xlf index fb9b12e4c..709c4d6a1 100644 --- a/Manager/MultilingualResources/Manager.fr.xlf +++ b/Manager/MultilingualResources/Manager.fr.xlf @@ -4242,6 +4242,28 @@ Il peut être pratique dans ce cas d'ajouter un commentaire pour noter les ticks The path contains non-basic latin characters which may lead to unexpected behaviors in-game. Please select a folder that contains only 7-bit ASCII characters. Le chemin contient des caractères qui peuvent entraîner des comportements inattendus dans le jeu. Veuillez sélectionner un dossier qui contient seulement des caractères ASCII. + + HLAE not found. Please install it by enabling it from settings. + HLAE introuvable. Veuillez l'installer en l'activant depuis les options. + + + Failed to close CSGO, please do it manually and try again. +Error: {0}. + La fermeture de CSGO a échoué, veuillez fermer CSGO manuellement puis réessayer. +Erreur: {0}. + + + Failed to close HLAE, please do it manually and try again. +Error: {0}. + La fermeture de HLAE a échoué, veuillez fermer HLAE manuellement puis réessayer. +Erreur: {0}. + + + Failed to start CSGO. +Error: {0}. + Une erreur est survenue lors du lancement de CSGO. +Error: {0}. + diff --git a/Manager/MultilingualResources/Manager.hr.xlf b/Manager/MultilingualResources/Manager.hr.xlf index 594f1e334..101886f92 100644 --- a/Manager/MultilingualResources/Manager.hr.xlf +++ b/Manager/MultilingualResources/Manager.hr.xlf @@ -4235,6 +4235,28 @@ Please update it by clicking on the "Update" button. The path contains non-basic latin characters which may lead to unexpected behaviors in-game. Please select a folder that contains only 7-bit ASCII characters. The path contains non-basic latin characters which may lead to unexpected behaviors in-game. Please select a folder that contains only 7-bit ASCII characters. + + HLAE not found. Please install it by enabling it from settings. + HLAE not found. Please install it by enabling it from settings. + + + Failed to close CSGO, please do it manually and try again. +Error: {0}. + Failed to close CSGO, please do it manually and try again. +Error: {0}. + + + Failed to close HLAE, please do it manually and try again. +Error: {0}. + Failed to close HLAE, please do it manually and try again. +Error: {0}. + + + Failed to start CSGO. +Error: {0}. + Failed to start CSGO. +Error: {0}. + diff --git a/Manager/MultilingualResources/Manager.hu.xlf b/Manager/MultilingualResources/Manager.hu.xlf index ad03c58a3..43ac30f71 100644 --- a/Manager/MultilingualResources/Manager.hu.xlf +++ b/Manager/MultilingualResources/Manager.hu.xlf @@ -4236,6 +4236,28 @@ Please update it by clicking on the "Update" button. The path contains non-basic latin characters which may lead to unexpected behaviors in-game. Please select a folder that contains only 7-bit ASCII characters. The path contains non-basic latin characters which may lead to unexpected behaviors in-game. Please select a folder that contains only 7-bit ASCII characters. + + HLAE not found. Please install it by enabling it from settings. + HLAE nem található. Kérem telepítse, úgy, hogy aktiválja a beállításokban. + + + Failed to close CSGO, please do it manually and try again. +Error: {0}. + Failed to close CSGO, please do it manually and try again. +Error: {0}. + + + Failed to close HLAE, please do it manually and try again. +Error: {0}. + Failed to close HLAE, please do it manually and try again. +Error: {0}. + + + Failed to start CSGO. +Error: {0}. + Failed to start CSGO. +Error: {0}. + diff --git a/Manager/MultilingualResources/Manager.it.xlf b/Manager/MultilingualResources/Manager.it.xlf index 2b790a843..67166d34d 100644 --- a/Manager/MultilingualResources/Manager.it.xlf +++ b/Manager/MultilingualResources/Manager.it.xlf @@ -4235,6 +4235,28 @@ Please update it by clicking on the "Update" button. The path contains non-basic latin characters which may lead to unexpected behaviors in-game. Please select a folder that contains only 7-bit ASCII characters. The path contains non-basic latin characters which may lead to unexpected behaviors in-game. Please select a folder that contains only 7-bit ASCII characters. + + HLAE not found. Please install it by enabling it from settings. + HLAE not found. Please install it by enabling it from settings. + + + Failed to close CSGO, please do it manually and try again. +Error: {0}. + Failed to close CSGO, please do it manually and try again. +Error: {0}. + + + Failed to close HLAE, please do it manually and try again. +Error: {0}. + Failed to close HLAE, please do it manually and try again. +Error: {0}. + + + Failed to start CSGO. +Error: {0}. + Failed to start CSGO. +Error: {0}. + diff --git a/Manager/MultilingualResources/Manager.ja.xlf b/Manager/MultilingualResources/Manager.ja.xlf index a978ad138..e5e8a93ca 100644 --- a/Manager/MultilingualResources/Manager.ja.xlf +++ b/Manager/MultilingualResources/Manager.ja.xlf @@ -4235,6 +4235,28 @@ Please update it by clicking on the "Update" button. The path contains non-basic latin characters which may lead to unexpected behaviors in-game. Please select a folder that contains only 7-bit ASCII characters. The path contains non-basic latin characters which may lead to unexpected behaviors in-game. Please select a folder that contains only 7-bit ASCII characters. + + HLAE not found. Please install it by enabling it from settings. + HLAE not found. Please install it by enabling it from settings. + + + Failed to close CSGO, please do it manually and try again. +Error: {0}. + Failed to close CSGO, please do it manually and try again. +Error: {0}. + + + Failed to close HLAE, please do it manually and try again. +Error: {0}. + Failed to close HLAE, please do it manually and try again. +Error: {0}. + + + Failed to start CSGO. +Error: {0}. + Failed to start CSGO. +Error: {0}. + diff --git a/Manager/MultilingualResources/Manager.nl.xlf b/Manager/MultilingualResources/Manager.nl.xlf index 4f05c2bb4..c31b492fc 100644 --- a/Manager/MultilingualResources/Manager.nl.xlf +++ b/Manager/MultilingualResources/Manager.nl.xlf @@ -4235,6 +4235,28 @@ Please update it by clicking on the "Update" button. The path contains non-basic latin characters which may lead to unexpected behaviors in-game. Please select a folder that contains only 7-bit ASCII characters. The path contains non-basic latin characters which may lead to unexpected behaviors in-game. Please select a folder that contains only 7-bit ASCII characters. + + HLAE not found. Please install it by enabling it from settings. + HLAE not found. Please install it by enabling it from settings. + + + Failed to close CSGO, please do it manually and try again. +Error: {0}. + Failed to close CSGO, please do it manually and try again. +Error: {0}. + + + Failed to close HLAE, please do it manually and try again. +Error: {0}. + Failed to close HLAE, please do it manually and try again. +Error: {0}. + + + Failed to start CSGO. +Error: {0}. + Failed to start CSGO. +Error: {0}. + diff --git a/Manager/MultilingualResources/Manager.pl.xlf b/Manager/MultilingualResources/Manager.pl.xlf index 235b55f38..9b85ac307 100644 --- a/Manager/MultilingualResources/Manager.pl.xlf +++ b/Manager/MultilingualResources/Manager.pl.xlf @@ -4236,6 +4236,28 @@ Please update it by clicking on the "Update" button. The path contains non-basic latin characters which may lead to unexpected behaviors in-game. Please select a folder that contains only 7-bit ASCII characters. The path contains non-basic latin characters which may lead to unexpected behaviors in-game. Please select a folder that contains only 7-bit ASCII characters. + + HLAE not found. Please install it by enabling it from settings. + Nie znaleziono HLAE. Zainstaluj HLAE włączając go w ustawieniach. + + + Failed to close CSGO, please do it manually and try again. +Error: {0}. + Failed to close CSGO, please do it manually and try again. +Error: {0}. + + + Failed to close HLAE, please do it manually and try again. +Error: {0}. + Failed to close HLAE, please do it manually and try again. +Error: {0}. + + + Failed to start CSGO. +Error: {0}. + Failed to start CSGO. +Error: {0}. + diff --git a/Manager/MultilingualResources/Manager.pt-BR.xlf b/Manager/MultilingualResources/Manager.pt-BR.xlf index 572c97754..6608d43c2 100644 --- a/Manager/MultilingualResources/Manager.pt-BR.xlf +++ b/Manager/MultilingualResources/Manager.pt-BR.xlf @@ -4236,6 +4236,28 @@ Please update it by clicking on the "Update" button. The path contains non-basic latin characters which may lead to unexpected behaviors in-game. Please select a folder that contains only 7-bit ASCII characters. The path contains non-basic latin characters which may lead to unexpected behaviors in-game. Please select a folder that contains only 7-bit ASCII characters. + + HLAE not found. Please install it by enabling it from settings. + HLAE não encontrado. Instale-o, permitindo as configurações. + + + Failed to close CSGO, please do it manually and try again. +Error: {0}. + Failed to close CSGO, please do it manually and try again. +Error: {0}. + + + Failed to close HLAE, please do it manually and try again. +Error: {0}. + Failed to close HLAE, please do it manually and try again. +Error: {0}. + + + Failed to start CSGO. +Error: {0}. + Failed to start CSGO. +Error: {0}. + diff --git a/Manager/MultilingualResources/Manager.pt.xlf b/Manager/MultilingualResources/Manager.pt.xlf index 0e067946c..6c2600212 100644 --- a/Manager/MultilingualResources/Manager.pt.xlf +++ b/Manager/MultilingualResources/Manager.pt.xlf @@ -4235,6 +4235,28 @@ Please update it by clicking on the "Update" button. The path contains non-basic latin characters which may lead to unexpected behaviors in-game. Please select a folder that contains only 7-bit ASCII characters. The path contains non-basic latin characters which may lead to unexpected behaviors in-game. Please select a folder that contains only 7-bit ASCII characters. + + HLAE not found. Please install it by enabling it from settings. + HLAE not found. Please install it by enabling it from settings. + + + Failed to close CSGO, please do it manually and try again. +Error: {0}. + Failed to close CSGO, please do it manually and try again. +Error: {0}. + + + Failed to close HLAE, please do it manually and try again. +Error: {0}. + Failed to close HLAE, please do it manually and try again. +Error: {0}. + + + Failed to start CSGO. +Error: {0}. + Failed to start CSGO. +Error: {0}. + diff --git a/Manager/MultilingualResources/Manager.ru.xlf b/Manager/MultilingualResources/Manager.ru.xlf index c0efedf0f..3fb3fd5af 100644 --- a/Manager/MultilingualResources/Manager.ru.xlf +++ b/Manager/MultilingualResources/Manager.ru.xlf @@ -4235,6 +4235,28 @@ Please update it by clicking on the "Update" button. The path contains non-basic latin characters which may lead to unexpected behaviors in-game. Please select a folder that contains only 7-bit ASCII characters. The path contains non-basic latin characters which may lead to unexpected behaviors in-game. Please select a folder that contains only 7-bit ASCII characters. + + HLAE not found. Please install it by enabling it from settings. + HLAE not found. Please install it by enabling it from settings. + + + Failed to close CSGO, please do it manually and try again. +Error: {0}. + Failed to close CSGO, please do it manually and try again. +Error: {0}. + + + Failed to close HLAE, please do it manually and try again. +Error: {0}. + Failed to close HLAE, please do it manually and try again. +Error: {0}. + + + Failed to start CSGO. +Error: {0}. + Failed to start CSGO. +Error: {0}. + diff --git a/Manager/MultilingualResources/Manager.sr-Cyrl.xlf b/Manager/MultilingualResources/Manager.sr-Cyrl.xlf index ddc4a708f..6eb0415d4 100644 --- a/Manager/MultilingualResources/Manager.sr-Cyrl.xlf +++ b/Manager/MultilingualResources/Manager.sr-Cyrl.xlf @@ -4235,6 +4235,28 @@ Please update it by clicking on the "Update" button. The path contains non-basic latin characters which may lead to unexpected behaviors in-game. Please select a folder that contains only 7-bit ASCII characters. The path contains non-basic latin characters which may lead to unexpected behaviors in-game. Please select a folder that contains only 7-bit ASCII characters. + + HLAE not found. Please install it by enabling it from settings. + HLAE not found. Please install it by enabling it from settings. + + + Failed to close CSGO, please do it manually and try again. +Error: {0}. + Failed to close CSGO, please do it manually and try again. +Error: {0}. + + + Failed to close HLAE, please do it manually and try again. +Error: {0}. + Failed to close HLAE, please do it manually and try again. +Error: {0}. + + + Failed to start CSGO. +Error: {0}. + Failed to start CSGO. +Error: {0}. + diff --git a/Manager/MultilingualResources/Manager.tr-TR.xlf b/Manager/MultilingualResources/Manager.tr-TR.xlf index c1d75d938..a300f30b7 100644 --- a/Manager/MultilingualResources/Manager.tr-TR.xlf +++ b/Manager/MultilingualResources/Manager.tr-TR.xlf @@ -4235,6 +4235,28 @@ Please update it by clicking on the "Update" button. The path contains non-basic latin characters which may lead to unexpected behaviors in-game. Please select a folder that contains only 7-bit ASCII characters. The path contains non-basic latin characters which may lead to unexpected behaviors in-game. Please select a folder that contains only 7-bit ASCII characters. + + HLAE not found. Please install it by enabling it from settings. + HLAE not found. Please install it by enabling it from settings. + + + Failed to close CSGO, please do it manually and try again. +Error: {0}. + Failed to close CSGO, please do it manually and try again. +Error: {0}. + + + Failed to close HLAE, please do it manually and try again. +Error: {0}. + Failed to close HLAE, please do it manually and try again. +Error: {0}. + + + Failed to start CSGO. +Error: {0}. + Failed to start CSGO. +Error: {0}. + diff --git a/Manager/MultilingualResources/Manager.tr.xlf b/Manager/MultilingualResources/Manager.tr.xlf index 2005ec9a3..525357707 100644 --- a/Manager/MultilingualResources/Manager.tr.xlf +++ b/Manager/MultilingualResources/Manager.tr.xlf @@ -4235,6 +4235,28 @@ Please update it by clicking on the "Update" button. The path contains non-basic latin characters which may lead to unexpected behaviors in-game. Please select a folder that contains only 7-bit ASCII characters. The path contains non-basic latin characters which may lead to unexpected behaviors in-game. Please select a folder that contains only 7-bit ASCII characters. + + HLAE not found. Please install it by enabling it from settings. + HLAE not found. Please install it by enabling it from settings. + + + Failed to close CSGO, please do it manually and try again. +Error: {0}. + Failed to close CSGO, please do it manually and try again. +Error: {0}. + + + Failed to close HLAE, please do it manually and try again. +Error: {0}. + Failed to close HLAE, please do it manually and try again. +Error: {0}. + + + Failed to start CSGO. +Error: {0}. + Failed to start CSGO. +Error: {0}. + diff --git a/Manager/MultilingualResources/Manager.zh-Hans.xlf b/Manager/MultilingualResources/Manager.zh-Hans.xlf index 9fece2f33..9cfeedf1c 100644 --- a/Manager/MultilingualResources/Manager.zh-Hans.xlf +++ b/Manager/MultilingualResources/Manager.zh-Hans.xlf @@ -4235,6 +4235,28 @@ Please update it by clicking on the "Update" button. The path contains non-basic latin characters which may lead to unexpected behaviors in-game. Please select a folder that contains only 7-bit ASCII characters. The path contains non-basic latin characters which may lead to unexpected behaviors in-game. Please select a folder that contains only 7-bit ASCII characters. + + HLAE not found. Please install it by enabling it from settings. + 无法找到HLAE引擎,请安装后在设置中启用. + + + Failed to close CSGO, please do it manually and try again. +Error: {0}. + Failed to close CSGO, please do it manually and try again. +Error: {0}. + + + Failed to close HLAE, please do it manually and try again. +Error: {0}. + Failed to close HLAE, please do it manually and try again. +Error: {0}. + + + Failed to start CSGO. +Error: {0}. + Failed to start CSGO. +Error: {0}. + diff --git a/Manager/MultilingualResources/Manager.zh-Hant.xlf b/Manager/MultilingualResources/Manager.zh-Hant.xlf index d81076a02..7616a9a69 100644 --- a/Manager/MultilingualResources/Manager.zh-Hant.xlf +++ b/Manager/MultilingualResources/Manager.zh-Hant.xlf @@ -4235,6 +4235,28 @@ Please update it by clicking on the "Update" button. The path contains non-basic latin characters which may lead to unexpected behaviors in-game. Please select a folder that contains only 7-bit ASCII characters. The path contains non-basic latin characters which may lead to unexpected behaviors in-game. Please select a folder that contains only 7-bit ASCII characters. + + HLAE not found. Please install it by enabling it from settings. + HLAE not found. Please install it by enabling it from settings. + + + Failed to close CSGO, please do it manually and try again. +Error: {0}. + Failed to close CSGO, please do it manually and try again. +Error: {0}. + + + Failed to close HLAE, please do it manually and try again. +Error: {0}. + Failed to close HLAE, please do it manually and try again. +Error: {0}. + + + Failed to start CSGO. +Error: {0}. + Failed to start CSGO. +Error: {0}. + diff --git a/Manager/Properties/Resources.Designer.cs b/Manager/Properties/Resources.Designer.cs index 460bbdd97..656eb7dd7 100644 --- a/Manager/Properties/Resources.Designer.cs +++ b/Manager/Properties/Resources.Designer.cs @@ -1702,6 +1702,26 @@ public static string DialogErrorInvalidSteamId { } } + /// + /// Looks up a localized string similar to Failed to close CSGO, please do it manually and try again. + ///Error: {0}.. + /// + public static string DialogErrorKillingCsgo { + get { + return ResourceManager.GetString("DialogErrorKillingCsgo", resourceCulture); + } + } + + /// + /// Looks up a localized string similar to Failed to close HLAE, please do it manually and try again. + ///Error: {0}.. + /// + public static string DialogErrorKillingHlae { + get { + return ResourceManager.GetString("DialogErrorKillingHlae", resourceCulture); + } + } + /// /// Looks up a localized string similar to An error occured while loading data. ///{0}. @@ -1730,6 +1750,16 @@ public static string DialogErrorSavingCommentDemo { } } + /// + /// Looks up a localized string similar to Failed to start CSGO. + ///Error: {0}.. + /// + public static string DialogErrorStartingCsgo { + get { + return ResourceManager.GetString("DialogErrorStartingCsgo", resourceCulture); + } + } + /// /// Looks up a localized string similar to An error occured while updating HLAE. ///{0}. @@ -5055,6 +5085,15 @@ public static string Hits { } } + /// + /// Looks up a localized string similar to HLAE not found. Please install it by enabling it from settings.. + /// + public static string HlaeNotFound { + get { + return ResourceManager.GetString("HlaeNotFound", resourceCulture); + } + } + /// /// Looks up a localized string similar to HLTV2 (HLTV2 Rating). /// diff --git a/Manager/Properties/Resources.es.resx b/Manager/Properties/Resources.es.resx index 8b4901a02..a3de346b4 100644 --- a/Manager/Properties/Resources.es.resx +++ b/Manager/Properties/Resources.es.resx @@ -2630,4 +2630,7 @@ Por favor introduce el código para compartir (ejemplo: CSGO-orkmt-Z8udN-apVEh-G Vista + + HLAE no encontrado. Por favor instálalo activándolo desde la configuración. + \ No newline at end of file diff --git a/Manager/Properties/Resources.fr.resx b/Manager/Properties/Resources.fr.resx index da32a7146..9ac4e0d69 100644 --- a/Manager/Properties/Resources.fr.resx +++ b/Manager/Properties/Resources.fr.resx @@ -3180,4 +3180,19 @@ Il peut être pratique dans ce cas d'ajouter un commentaire pour noter les ticks Le chemin contient des caractères qui peuvent entraîner des comportements inattendus dans le jeu. Veuillez sélectionner un dossier qui contient seulement des caractères ASCII. + + HLAE introuvable. Veuillez l'installer en l'activant depuis les options. + + + La fermeture de CSGO a échoué, veuillez fermer CSGO manuellement puis réessayer. +Erreur: {0}. + + + La fermeture de HLAE a échoué, veuillez fermer HLAE manuellement puis réessayer. +Erreur: {0}. + + + Une erreur est survenue lors du lancement de CSGO. +Error: {0}. + \ No newline at end of file diff --git a/Manager/Properties/Resources.hu.resx b/Manager/Properties/Resources.hu.resx index b1b94813a..4534f4fa7 100644 --- a/Manager/Properties/Resources.hu.resx +++ b/Manager/Properties/Resources.hu.resx @@ -2671,4 +2671,7 @@ Kérem adja meg a megosztási-kódot. (Például: CSGO-orkmt-Z8udN-apVEh-GQtx3-s {0} Lehet, hogy hiányoznak adatok a demókhoz. + + HLAE nem található. Kérem telepítse, úgy, hogy aktiválja a beállításokban. + \ No newline at end of file diff --git a/Manager/Properties/Resources.pl.resx b/Manager/Properties/Resources.pl.resx index ffb18abe0..8b6eb5f56 100644 --- a/Manager/Properties/Resources.pl.resx +++ b/Manager/Properties/Resources.pl.resx @@ -2578,4 +2578,7 @@ Czy chcesz ją zainstalować? (Zalecane by uniknąć crashów w związku z aktua Obejrzane + + Nie znaleziono HLAE. Zainstaluj HLAE włączając go w ustawieniach. + \ No newline at end of file diff --git a/Manager/Properties/Resources.pt-BR.resx b/Manager/Properties/Resources.pt-BR.resx index 405f6b81f..2d53039a9 100644 --- a/Manager/Properties/Resources.pt-BR.resx +++ b/Manager/Properties/Resources.pt-BR.resx @@ -2637,4 +2637,7 @@ Digite link de compartilhamento (exemplo: CSGO-orkmt-Z8udN-apVEh-GQtx3-sU7CR). Assistido + + HLAE não encontrado. Instale-o, permitindo as configurações. + \ No newline at end of file diff --git a/Manager/Properties/Resources.resx b/Manager/Properties/Resources.resx index 4b0b0539f..faf80dc34 100644 --- a/Manager/Properties/Resources.resx +++ b/Manager/Properties/Resources.resx @@ -3285,4 +3285,19 @@ Please update it by clicking on the "Update" button. The path contains non-basic latin characters which may lead to unexpected behaviors in-game. Please select a folder that contains only 7-bit ASCII characters. + + Failed to close CSGO, please do it manually and try again. +Error: {0}. + + + Failed to close HLAE, please do it manually and try again. +Error: {0}. + + + Failed to start CSGO. +Error: {0}. + + + HLAE not found. Please install it by enabling it from settings. + \ No newline at end of file diff --git a/Manager/Properties/Resources.zh-Hans.resx b/Manager/Properties/Resources.zh-Hans.resx index 89fd7c1a3..8cac97ec0 100644 --- a/Manager/Properties/Resources.zh-Hans.resx +++ b/Manager/Properties/Resources.zh-Hans.resx @@ -3131,4 +3131,7 @@ 启用国际服务器启动参数 (-worldwide) Enable -worldwide startup parameter + + 无法找到HLAE引擎,请安装后在设置中启用. + \ No newline at end of file diff --git a/Manager/Services/DialogService.cs b/Manager/Services/DialogService.cs index a85a0d7ff..b7d67e8b1 100644 --- a/Manager/Services/DialogService.cs +++ b/Manager/Services/DialogService.cs @@ -109,14 +109,6 @@ public async Task ShowAnalyzeAllDemosAsync() MessageDialogStyle.AffirmativeAndNegativeAndSingleAuxiliary, dialogOptions); } - public async Task ShowSteamNotFoundAsync() - { - string errorMessage = Properties.Resources.DialogSteamNotFound; - - var metroWindow = Application.Current.MainWindow as MetroWindow; - return await metroWindow.ShowMessageAsync(Properties.Resources.Error, errorMessage); - } - public async Task ShowHighLowWatchAsync() { MetroWindow metroWindow = Application.Current.MainWindow as MetroWindow; diff --git a/Manager/Services/IDialogService.cs b/Manager/Services/IDialogService.cs index c5d47b2e8..000d83925 100644 --- a/Manager/Services/IDialogService.cs +++ b/Manager/Services/IDialogService.cs @@ -31,8 +31,6 @@ public interface IDialogService Task ShowAnalyzeAllDemosAsync(); - Task ShowSteamNotFoundAsync(); - Task ShowHighLowWatchAsync(); Task ShowHeatmapDataNotFoundAsync(string eventType); diff --git a/Manager/ViewModel/Demos/DemoDetailsViewModel.cs b/Manager/ViewModel/Demos/DemoDetailsViewModel.cs index 5a32d2737..56ffcfbb7 100644 --- a/Manager/ViewModel/Demos/DemoDetailsViewModel.cs +++ b/Manager/ViewModel/Demos/DemoDetailsViewModel.cs @@ -453,22 +453,17 @@ public RelayCommand WatchPlayerCommand ?? (_watchPlayerCommand = new RelayCommand( async player => { - if (AppSettings.SteamExePath() == null) + try { - await _dialogService.ShowMessageAsync(Properties.Resources.DialogSteamNotFound, MessageDialogStyle.Affirmative); - return; + GameLauncherConfiguration config = Config.BuildGameLauncherConfiguration(Demo); + config.FocusPlayerSteamId = player.SteamId; + GameLauncher launcher = new GameLauncher(config); + await launcher.WatchPlayer(); } - - Round firstRound = Demo.Rounds.FirstOrDefault(); - if (firstRound == null) + catch (Exception ex) { - return; + await HandleGameLauncherException(ex); } - - GameLauncherConfiguration config = Config.BuildGameLauncherConfiguration(Demo); - config.FocusPlayerSteamId = player.SteamId; - GameLauncher launcher = new GameLauncher(config); - launcher.WatchPlayer(); }, suspect => SelectedPlayer != null)); } @@ -482,22 +477,23 @@ public RelayCommand WatchHighlights ?? (_watchHighlightsCommand = new RelayCommand( async player => { - if (AppSettings.SteamExePath() == null) + try { - await _dialogService.ShowMessageAsync(Properties.Resources.DialogSteamNotFound, MessageDialogStyle.Affirmative); - return; - } + GameLauncherConfiguration config = Config.BuildGameLauncherConfiguration(Demo); + config.FocusPlayerSteamId = player.SteamId; + GameLauncher launcher = new GameLauncher(config); + var isPlayerPerspective = await _dialogService.ShowHighLowWatchAsync(); + if (isPlayerPerspective == MessageDialogResult.FirstAuxiliary) + { + return; + } - GameLauncherConfiguration config = Config.BuildGameLauncherConfiguration(Demo); - config.FocusPlayerSteamId = player.SteamId; - GameLauncher launcher = new GameLauncher(config); - var isPlayerPerspective = await _dialogService.ShowHighLowWatchAsync(); - if (isPlayerPerspective == MessageDialogResult.FirstAuxiliary) + await launcher.WatchHighlightDemo(isPlayerPerspective == MessageDialogResult.Affirmative); + } + catch (Exception ex) { - return; + await HandleGameLauncherException(ex); } - - launcher.WatchHighlightDemo(isPlayerPerspective == MessageDialogResult.Affirmative); }, suspect => SelectedPlayer != null)); } @@ -511,22 +507,22 @@ public RelayCommand WatchLowlights ?? (_watchLowlightsCommand = new RelayCommand( async player => { - if (AppSettings.SteamExePath() == null) + try { - await _dialogService.ShowMessageAsync(Properties.Resources.DialogSteamNotFound, MessageDialogStyle.Affirmative); - return; + GameLauncherConfiguration config = Config.BuildGameLauncherConfiguration(Demo); + config.FocusPlayerSteamId = player.SteamId; + GameLauncher launcher = new GameLauncher(config); + var isPlayerPerspective = await _dialogService.ShowHighLowWatchAsync(); + if (isPlayerPerspective == MessageDialogResult.FirstAuxiliary) + { + return; + } + await launcher.WatchLowlightDemo(isPlayerPerspective == MessageDialogResult.Affirmative); } - - GameLauncherConfiguration config = Config.BuildGameLauncherConfiguration(Demo); - config.FocusPlayerSteamId = player.SteamId; - GameLauncher launcher = new GameLauncher(config); - var isPlayerPerspective = await _dialogService.ShowHighLowWatchAsync(); - if (isPlayerPerspective == MessageDialogResult.FirstAuxiliary) + catch (Exception ex) { - return; + await HandleGameLauncherException(ex); } - - launcher.WatchLowlightDemo(isPlayerPerspective == MessageDialogResult.Affirmative); }, suspect => SelectedPlayer != null)); } @@ -677,16 +673,17 @@ public RelayCommand WatchRoundCommand ?? (_watchRoundCommand = new RelayCommand( async round => { - if (AppSettings.SteamExePath() == null) + try { - await _dialogService.ShowMessageAsync(Properties.Resources.DialogSteamNotFound, MessageDialogStyle.Affirmative); - return; + GameLauncherConfiguration config = Config.BuildGameLauncherConfiguration(Demo); + config.FocusPlayerSteamId = Settings.Default.WatchAccountSteamId; + GameLauncher launcher = new GameLauncher(config); + await launcher.WatchDemoAt(round.Tick); + } + catch (Exception ex) + { + await HandleGameLauncherException(ex); } - - GameLauncherConfiguration config = Config.BuildGameLauncherConfiguration(Demo); - config.FocusPlayerSteamId = Settings.Default.WatchAccountSteamId; - GameLauncher launcher = new GameLauncher(config); - launcher.WatchDemoAt(round.Tick); }, round => Demo != null && SelectedRound != null)); } diff --git a/Manager/ViewModel/Demos/DemoListViewModel.cs b/Manager/ViewModel/Demos/DemoListViewModel.cs index 30690fdde..a6c7c25ec 100644 --- a/Manager/ViewModel/Demos/DemoListViewModel.cs +++ b/Manager/ViewModel/Demos/DemoListViewModel.cs @@ -775,12 +775,6 @@ public RelayCommand GoToTickCommand ?? (_goToTickCommand = new RelayCommand( async demo => { - if (AppSettings.SteamExePath() == null) - { - await _dialogService.ShowMessageAsync(Properties.Resources.DialogSteamNotFound, MessageDialogStyle.Affirmative); - return; - } - var result = await _dialogService.ShowInputAsync(Properties.Resources.DialogGoToTick, Properties.Resources.DialogEnterTick); if (string.IsNullOrEmpty(result)) @@ -798,12 +792,11 @@ public RelayCommand GoToTickCommand GameLauncherConfiguration config = Config.BuildGameLauncherConfiguration(demo); config.FocusPlayerSteamId = Properties.Settings.Default.WatchAccountSteamId; GameLauncher launcher = new GameLauncher(config); - launcher.WatchDemoAt(tick); + await launcher.WatchDemoAt(tick); } - catch (Exception e) + catch (Exception ex) { - Logger.Instance.Log(e); - await _dialogService.ShowErrorAsync(e.Message, MessageDialogStyle.Affirmative); + await HandleGameLauncherException(ex); } } else @@ -1009,23 +1002,16 @@ public RelayCommand WatchDemoCommand ?? (_watchDemoCommand = new RelayCommand( async demo => { - if (AppSettings.SteamExePath() == null) - { - await _dialogService.ShowMessageAsync(Properties.Resources.DialogSteamNotFound, MessageDialogStyle.Affirmative); - return; - } - try { GameLauncherConfiguration config = Config.BuildGameLauncherConfiguration(demo); config.FocusPlayerSteamId = Properties.Settings.Default.WatchAccountSteamId; GameLauncher launcher = new GameLauncher(config); - await launcher.StartGame(); + await launcher.WatchDemo(); } - catch (Exception e) + catch (Exception ex) { - Logger.Instance.Log(e); - await _dialogService.ShowErrorAsync(e.Message, MessageDialogStyle.Affirmative); + await HandleGameLauncherException(ex); } }, demo => demo != null)); @@ -2127,19 +2113,12 @@ await _dialogService.ShowMessageAsync(string.Format(Properties.Resources.DialogD /// /// Check if the user is able to use the highlight / lowlight from the demos list - /// - Steam is required /// - An account has to be selected /// - The selected account must be in the selected demo /// /// private async Task ValidateHighLowWatch(Demo demo) { - if (AppSettings.SteamExePath() == null) - { - await _dialogService.ShowMessageAsync(Properties.Resources.DialogSteamNotFound, MessageDialogStyle.Affirmative); - return false; - } - if (Properties.Settings.Default.WatchAccountSteamId == 0) { await _dialogService.ShowMessageAsync(Properties.Resources.DialogSetAccountToFocus, MessageDialogStyle.Affirmative); @@ -2156,48 +2135,38 @@ private async Task ValidateHighLowWatch(Demo demo) return true; } - /// - /// Launch highlights or lowlights - /// - /// - private async void StartWatchHighOrLow(Demo demo, bool isHighlight = true) - { - GameLauncherConfiguration config = Config.BuildGameLauncherConfiguration(demo); - config.FocusPlayerSteamId = Properties.Settings.Default.WatchAccountSteamId; - GameLauncher launcher = new GameLauncher(config); - var isPlayerPerspective = await _dialogService.ShowHighLowWatchAsync(); - if (isPlayerPerspective == MessageDialogResult.FirstAuxiliary) - { - return; - } - - if (isHighlight) - { - launcher.WatchHighlightDemo(isPlayerPerspective == MessageDialogResult.Affirmative); - } - else - { - launcher.WatchLowlightDemo(isPlayerPerspective == MessageDialogResult.Affirmative); - } - } - /// /// Process when the user want to watch highlights or lowlights /// private async Task ProcessWatchHighOrLow(Demo demo, bool isHighlight = true) { - bool isWatchValidated = await ValidateHighLowWatch(demo); try { + bool isWatchValidated = await ValidateHighLowWatch(demo); if (isWatchValidated) { - StartWatchHighOrLow(demo, isHighlight); + GameLauncherConfiguration config = Config.BuildGameLauncherConfiguration(demo); + config.FocusPlayerSteamId = Properties.Settings.Default.WatchAccountSteamId; + GameLauncher launcher = new GameLauncher(config); + var isPlayerPerspective = await _dialogService.ShowHighLowWatchAsync(); + if (isPlayerPerspective == MessageDialogResult.FirstAuxiliary) + { + return; + } + + if (isHighlight) + { + await launcher.WatchHighlightDemo(isPlayerPerspective == MessageDialogResult.Affirmative); + } + else + { + await launcher.WatchLowlightDemo(isPlayerPerspective == MessageDialogResult.Affirmative); + } } } - catch (Exception e) + catch (Exception ex) { - Logger.Instance.Log(e); - await _dialogService.ShowErrorAsync(e.Message, MessageDialogStyle.Affirmative); + await HandleGameLauncherException(ex); } } diff --git a/Manager/ViewModel/Demos/DemoMovieViewModel.cs b/Manager/ViewModel/Demos/DemoMovieViewModel.cs index a3a2862ba..081238331 100644 --- a/Manager/ViewModel/Demos/DemoMovieViewModel.cs +++ b/Manager/ViewModel/Demos/DemoMovieViewModel.cs @@ -799,11 +799,9 @@ await _dialogService.ShowErrorAsync(Properties.Resources.DialogEndTickGreaterTha await _movieService.Start(); // TODO notification } - catch (Exception e) + catch (Exception ex) { - Logger.Instance.Log(e); - await _dialogService.ShowErrorAsync(string.Format(Properties.Resources.DialogErrorWhileGeneratingVideo, e.Message), - MessageDialogStyle.Affirmative); + await HandleGameLauncherException(ex, string.Format(Properties.Resources.DialogErrorWhileGeneratingVideo, ex.Message)); } finally { diff --git a/Manager/ViewModel/Demos/DemoStuffsViewModel.cs b/Manager/ViewModel/Demos/DemoStuffsViewModel.cs index 7a91a4121..7c8d66026 100644 --- a/Manager/ViewModel/Demos/DemoStuffsViewModel.cs +++ b/Manager/ViewModel/Demos/DemoStuffsViewModel.cs @@ -186,16 +186,18 @@ public RelayCommand WatchStuff ?? (_watchStuff = new RelayCommand( async () => { - if (AppSettings.SteamExePath() == null) + try { - await _dialogService.ShowSteamNotFoundAsync(); - return; + GameLauncherConfiguration config = Config.BuildGameLauncherConfiguration(Demo); + config.FocusPlayerSteamId = SelectedStuff.ThrowerSteamId; + GameLauncher launcher = new GameLauncher(config); + await launcher.WatchDemoAt(SelectedStuff.Tick, true); + } + catch (Exception ex) + { + await HandleGameLauncherException(ex); } - GameLauncherConfiguration config = Config.BuildGameLauncherConfiguration(Demo); - config.FocusPlayerSteamId = SelectedStuff.ThrowerSteamId; - GameLauncher launcher = new GameLauncher(config); - launcher.WatchDemoAt(SelectedStuff.Tick, true); }, () => SelectedStuff != null)); } } @@ -208,16 +210,17 @@ public RelayCommand WatchPlayerStuffCommand ?? (_watchPlayerStuffCommand = new RelayCommand( async () => { - if (AppSettings.SteamExePath() == null) + try { - await _dialogService.ShowSteamNotFoundAsync(); - return; + GameLauncherConfiguration config = Config.BuildGameLauncherConfiguration(Demo); + config.FocusPlayerSteamId = SelectedPlayer.SteamId; + GameLauncher launcher = new GameLauncher(config); + await launcher.WatchPlayerStuff(SelectedPlayer, CurrentStuffSelector.Id); + } + catch (Exception ex) + { + await HandleGameLauncherException(ex); } - - GameLauncherConfiguration config = Config.BuildGameLauncherConfiguration(Demo); - config.FocusPlayerSteamId = SelectedPlayer.SteamId; - GameLauncher launcher = new GameLauncher(config); - launcher.WatchPlayerStuff(SelectedPlayer, CurrentStuffSelector.Id); }, () => Demo != null && SelectedPlayer != null)); } } diff --git a/Manager/ViewModel/Players/PlayerDetailsViewModel.cs b/Manager/ViewModel/Players/PlayerDetailsViewModel.cs index 8b6b5ed09..607ac913e 100644 --- a/Manager/ViewModel/Players/PlayerDetailsViewModel.cs +++ b/Manager/ViewModel/Players/PlayerDetailsViewModel.cs @@ -147,16 +147,17 @@ public RelayCommand WatchDemoWithDelayCommand ?? (_watchDemoWithDelayCommand = new RelayCommand( async tick => { - if (AppSettings.SteamExePath() == null) + try { - await _dialogService.ShowSteamNotFoundAsync(); - return; + GameLauncherConfiguration config = Config.BuildGameLauncherConfiguration(Demo); + config.FocusPlayerSteamId = CurrentPlayer.SteamId; + GameLauncher launcher = new GameLauncher(config); + await launcher.WatchDemoAt(tick, true); + } + catch (Exception ex) + { + await HandleGameLauncherException(ex); } - - GameLauncherConfiguration config = Config.BuildGameLauncherConfiguration(Demo); - config.FocusPlayerSteamId = CurrentPlayer.SteamId; - GameLauncher launcher = new GameLauncher(config); - launcher.WatchDemoAt(tick, true); })); } } @@ -169,16 +170,17 @@ public RelayCommand WatchDemoWithoutDelayCommand ?? (_watchDemoWithoutDelayCommand = new RelayCommand( async tick => { - if (AppSettings.SteamExePath() == null) + try { - await _dialogService.ShowSteamNotFoundAsync(); - return; + GameLauncherConfiguration config = Config.BuildGameLauncherConfiguration(Demo); + config.FocusPlayerSteamId = CurrentPlayer.SteamId; + GameLauncher launcher = new GameLauncher(config); + await launcher.WatchDemoAt(tick); + } + catch (Exception ex) + { + await HandleGameLauncherException(ex); } - - GameLauncherConfiguration config = Config.BuildGameLauncherConfiguration(Demo); - config.FocusPlayerSteamId = CurrentPlayer.SteamId; - GameLauncher launcher = new GameLauncher(config); - launcher.WatchDemoAt(tick); })); } } @@ -191,22 +193,23 @@ public RelayCommand WatchHighlightsCommand ?? (_watchHighlightsCommand = new RelayCommand( async () => { - if (AppSettings.SteamExePath() == null) + try { - await _dialogService.ShowMessageAsync(Properties.Resources.DialogSteamNotFound, MessageDialogStyle.Affirmative); - return; - } + GameLauncherConfiguration config = Config.BuildGameLauncherConfiguration(Demo); + config.FocusPlayerSteamId = CurrentPlayer.SteamId; + GameLauncher launcher = new GameLauncher(config); + var isPlayerPerspective = await _dialogService.ShowHighLowWatchAsync(); + if (isPlayerPerspective == MessageDialogResult.FirstAuxiliary) + { + return; + } - GameLauncherConfiguration config = Config.BuildGameLauncherConfiguration(Demo); - config.FocusPlayerSteamId = CurrentPlayer.SteamId; - GameLauncher launcher = new GameLauncher(config); - var isPlayerPerspective = await _dialogService.ShowHighLowWatchAsync(); - if (isPlayerPerspective == MessageDialogResult.FirstAuxiliary) + await launcher.WatchHighlightDemo(isPlayerPerspective == MessageDialogResult.Affirmative); + } + catch (Exception ex) { - return; + await HandleGameLauncherException(ex); } - - launcher.WatchHighlightDemo(isPlayerPerspective == MessageDialogResult.Affirmative); })); } } @@ -219,22 +222,23 @@ public RelayCommand WatchLowlightsCommand ?? (_watchLowlightsCommand = new RelayCommand( async () => { - if (AppSettings.SteamExePath() == null) + try { - await _dialogService.ShowMessageAsync(Properties.Resources.DialogSteamNotFound, MessageDialogStyle.Affirmative); - return; - } + GameLauncherConfiguration config = Config.BuildGameLauncherConfiguration(Demo); + config.FocusPlayerSteamId = CurrentPlayer.SteamId; + GameLauncher launcher = new GameLauncher(config); + var isPlayerPerspective = await _dialogService.ShowHighLowWatchAsync(); + if (isPlayerPerspective == MessageDialogResult.FirstAuxiliary) + { + return; + } - GameLauncherConfiguration config = Config.BuildGameLauncherConfiguration(Demo); - config.FocusPlayerSteamId = CurrentPlayer.SteamId; - GameLauncher launcher = new GameLauncher(config); - var isPlayerPerspective = await _dialogService.ShowHighLowWatchAsync(); - if (isPlayerPerspective == MessageDialogResult.FirstAuxiliary) + await launcher.WatchLowlightDemo(isPlayerPerspective == MessageDialogResult.Affirmative); + } + catch (Exception ex) { - return; + await HandleGameLauncherException(ex); } - - launcher.WatchLowlightDemo(isPlayerPerspective == MessageDialogResult.Affirmative); })); } } diff --git a/Manager/ViewModel/Rounds/RoundDetailsViewModel.cs b/Manager/ViewModel/Rounds/RoundDetailsViewModel.cs index 8566ac817..ceb01f44d 100644 --- a/Manager/ViewModel/Rounds/RoundDetailsViewModel.cs +++ b/Manager/ViewModel/Rounds/RoundDetailsViewModel.cs @@ -131,16 +131,17 @@ public RelayCommand WatchRoundCommand ?? (_watchRoundCommand = new RelayCommand( async () => { - if (AppSettings.SteamExePath() == null) + try { - await _dialogService.ShowMessageAsync(Properties.Resources.DialogSteamNotFound, MessageDialogStyle.Affirmative); - return; + GameLauncherConfiguration config = Config.BuildGameLauncherConfiguration(Demo); + config.FocusPlayerSteamId = Settings.Default.WatchAccountSteamId; + GameLauncher launcher = new GameLauncher(config); + await launcher.WatchDemoAt(CurrentRound.Tick); + } + catch (Exception ex) + { + await HandleGameLauncherException(ex); } - - GameLauncherConfiguration config = Config.BuildGameLauncherConfiguration(Demo); - config.FocusPlayerSteamId = Settings.Default.WatchAccountSteamId; - GameLauncher launcher = new GameLauncher(config); - launcher.WatchDemoAt(CurrentRound.Tick); }, () => CurrentRound != null)); } @@ -214,16 +215,17 @@ public RelayCommand WatchKillCommand ?? (_watchKillCommand = new RelayCommand( async kill => { - if (AppSettings.SteamExePath() == null) + try { - await _dialogService.ShowSteamNotFoundAsync(); - return; + GameLauncherConfiguration config = Config.BuildGameLauncherConfiguration(Demo); + config.FocusPlayerSteamId = kill.KillerSteamId; + GameLauncher launcher = new GameLauncher(config); + await launcher.WatchDemoAt(kill.Tick, true); + } + catch (Exception ex) + { + await HandleGameLauncherException(ex); } - - GameLauncherConfiguration config = Config.BuildGameLauncherConfiguration(Demo); - config.FocusPlayerSteamId = kill.KillerSteamId; - GameLauncher launcher = new GameLauncher(config); - launcher.WatchDemoAt(kill.Tick, true); })); } } diff --git a/Manager/ViewModel/Shared/BaseViewModel.cs b/Manager/ViewModel/Shared/BaseViewModel.cs index 1eedc366d..d24d9541d 100644 --- a/Manager/ViewModel/Shared/BaseViewModel.cs +++ b/Manager/ViewModel/Shared/BaseViewModel.cs @@ -1,6 +1,13 @@ -using System.Diagnostics; +using System; +using System.Diagnostics; +using System.Threading.Tasks; +using Core; using GalaSoft.MvvmLight; using GalaSoft.MvvmLight.CommandWpf; +using GalaSoft.MvvmLight.Ioc; +using MahApps.Metro.Controls.Dialogs; +using Manager.Services; +using Services.Exceptions.Launcher; namespace Manager.ViewModel.Shared { @@ -14,6 +21,8 @@ public class BaseViewModel : ViewModelBase private RelayCommand _handleHyperLinkCommand; + private readonly IDialogService _dialogService = SimpleIoc.Default.GetInstance(); + public bool HasNotification { get => _hasNotification; @@ -42,6 +51,29 @@ public RelayCommand HandleHyperLinkCommand } } + protected async Task HandleGameLauncherException(Exception ex, string defaultMessage = null) + { + Logger.Instance.Log(ex); + string message = defaultMessage ?? string.Format(Properties.Resources.DialogErrorStartingCsgo, ex.Message); + switch (ex) + { + case SteamExecutableNotFoundException _: + message = Properties.Resources.DialogSteamNotFound; + break; + case HlaeNotFound _: + message = Properties.Resources.HlaeNotFound; + break; + case KillCsgoException _: + message = string.Format(Properties.Resources.DialogErrorKillingCsgo, ex.InnerException != null ? ex.InnerException.Message : ex.Message); + break; + case KillHlaeException _: + message = string.Format(Properties.Resources.DialogErrorKillingHlae, ex.InnerException != null ? ex.InnerException.Message : ex.Message); + break; + } + + await _dialogService.ShowErrorAsync(message, MessageDialogStyle.Affirmative); + } + public override void Cleanup() { base.Cleanup(); diff --git a/Services/Concrete/GameLauncher.cs b/Services/Concrete/GameLauncher.cs index d4cdf96ce..17cb9e706 100644 --- a/Services/Concrete/GameLauncher.cs +++ b/Services/Concrete/GameLauncher.cs @@ -56,26 +56,13 @@ public GameLauncher(GameLauncherConfiguration config) _arguments.Add(_config.Demo.Path); } - public async Task StartGame() + private async Task StartGame() { SetupResolutionParameters(); SetupWorldwideParameter(); - KillCsgo(); + if (_config.EnableHlae) { - // start the game using HLAE - if (!File.Exists(_config.CsgoExePath)) - { - throw new CsgoNotFoundException(); - } - - if (!File.Exists(_config.HlaeExePath)) - { - throw new HlaeNotFound(); - } - - KillHlae(); - _arguments.Add(_config.LaunchParameters); List argList = new List(_hlaeArguments) { @@ -122,7 +109,7 @@ public async Task StartGame() if (_config.DeleteVdmFileAtStratup) { - await DeleteVdmFile(); + DeleteVdmFile(); } _config.OnGameStarted?.Invoke(); @@ -141,7 +128,7 @@ public async Task StartGame() if (_config.DeleteVdmFileWhenClosed) { - await DeleteVdmFile(); + DeleteVdmFile(); } } @@ -190,20 +177,24 @@ private void SetupWorldwideParameter() } } - private Task DeleteVdmFile() + private void DeleteVdmFile() { - return Task.Run(() => + string vdmPath = _config.Demo.GetVdmFilePath(); + if (File.Exists(vdmPath)) { - string vdmPath = _config.Demo.GetVdmFilePath(); - if (File.Exists(vdmPath)) - { - File.Delete(vdmPath); - } - }); + File.Delete(vdmPath); + } } - public async void WatchHighlightDemo(bool fromPlayerPerspective) + public async Task WatchDemo() { + PrepareGameLaunching(); + await StartGame(); + } + + public async Task WatchHighlightDemo(bool fromPlayerPerspective) + { + PrepareGameLaunching(); if (_config.UseCustomActionsGeneration) { GenerateHighLowVdm(true, fromPlayerPerspective); @@ -225,8 +216,9 @@ public async void WatchHighlightDemo(bool fromPlayerPerspective) await StartGame(); } - public async void WatchLowlightDemo(bool fromPlayerPerspective) + public async Task WatchLowlightDemo(bool fromPlayerPerspective) { + PrepareGameLaunching(); if (_config.UseCustomActionsGeneration) { GenerateHighLowVdm(false, fromPlayerPerspective); @@ -249,8 +241,9 @@ public async void WatchLowlightDemo(bool fromPlayerPerspective) await StartGame(); } - public async void WatchDemoAt(int tick, bool delay = false) + public async Task WatchDemoAt(int tick, bool delay = false) { + PrepareGameLaunching(); if (delay) { int tickDelayCount = (int)(_config.Demo.ServerTickrate * PLAYBACK_DELAY); @@ -260,8 +253,7 @@ public async void WatchDemoAt(int tick, bool delay = false) } } - string generated = string.Empty; - generated += string.Format(Properties.Resources.skip_ahead, 1, 1, tick); + string generated = string.Format(Properties.Resources.skip_ahead, 1, 1, tick); if (_config.FocusPlayerSteamId > 0) { generated += string.Format(Properties.Resources.spec_player, 2, tick + 1, _config.FocusPlayerSteamId); @@ -273,8 +265,9 @@ public async void WatchDemoAt(int tick, bool delay = false) await StartGame(); } - public async void WatchPlayerStuff(Player player, string selectedType) + public async Task WatchPlayerStuff(Player player, string selectedType) { + PrepareGameLaunching(); EquipmentElement type = EquipmentElement.Unknown; switch (selectedType) { @@ -300,13 +293,39 @@ public async void WatchPlayerStuff(Player player, string selectedType) await StartGame(); } - public async void WatchPlayer() + public async Task WatchPlayer() { + PrepareGameLaunching(); GenerateWatchPlayerVdm(); _config.DeleteVdmFileAtStratup = false; await StartGame(); } + private void PrepareGameLaunching() + { + KillCsgo(); + if (_config.EnableHlae) + { + KillHlae(); + if (!File.Exists(_config.CsgoExePath)) + { + throw new CsgoNotFoundException(); + } + + if (!File.Exists(_config.HlaeExePath)) + { + throw new HlaeNotFound(); + } + } + else + { + if (!File.Exists(_config.SteamExePath)) + { + throw new SteamExecutableNotFoundException(); + } + } + } + private void GeneratePlayerStuffVdm(Player player, EquipmentElement type) { Demo demo = _config.Demo; @@ -614,12 +633,26 @@ private static string GetFastForwardMessage(EquipmentElement type) private static void KillHlae() { - KillProcessByName("HLAE"); + try + { + KillProcessByName("HLAE"); + } + catch (Exception ex) + { + throw new KillHlaeException(ex); + } } private static void KillCsgo() { - KillProcessByName("csgo"); + try + { + KillProcessByName("csgo"); + } + catch (Exception ex) + { + throw new KillCsgoException(ex); + } } private static void KillProcessByName(string processName) diff --git a/Services/Concrete/Movie/MovieService.cs b/Services/Concrete/Movie/MovieService.cs index f570158c6..13979d966 100644 --- a/Services/Concrete/Movie/MovieService.cs +++ b/Services/Concrete/Movie/MovieService.cs @@ -105,7 +105,7 @@ public async Task Start() }; GameLauncher launcher = new GameLauncher(config); - await launcher.StartGame(); + await launcher.WatchDemo(); } else { diff --git a/Services/Exceptions/Launcher/HlaeNotFound.cs b/Services/Exceptions/Launcher/HlaeNotFound.cs index 845a92bc5..9c7385167 100644 --- a/Services/Exceptions/Launcher/HlaeNotFound.cs +++ b/Services/Exceptions/Launcher/HlaeNotFound.cs @@ -4,7 +4,7 @@ namespace Services.Exceptions.Launcher { public class HlaeNotFound : Exception { - public HlaeNotFound() : base(Properties.Resources.HlaeNotFoundException) + public HlaeNotFound() : base("HLAE.exe not found") { } } diff --git a/Services/Exceptions/Launcher/KillCsgoException.cs b/Services/Exceptions/Launcher/KillCsgoException.cs new file mode 100644 index 000000000..11d9e317d --- /dev/null +++ b/Services/Exceptions/Launcher/KillCsgoException.cs @@ -0,0 +1,11 @@ +using System; + +namespace Services.Exceptions.Launcher +{ + public class KillCsgoException : Exception + { + public KillCsgoException(Exception innerException) : base("Failed to kill CSGO process", innerException) + { + } + } +} diff --git a/Services/Exceptions/Launcher/KillHlaeException.cs b/Services/Exceptions/Launcher/KillHlaeException.cs new file mode 100644 index 000000000..72123b310 --- /dev/null +++ b/Services/Exceptions/Launcher/KillHlaeException.cs @@ -0,0 +1,11 @@ +using System; + +namespace Services.Exceptions.Launcher +{ + public class KillHlaeException : Exception + { + public KillHlaeException(Exception innerException) : base("Failed to kill HLAE process", innerException) + { + } + } +} diff --git a/Services/Exceptions/Launcher/SteamExecutableNotFoundException.cs b/Services/Exceptions/Launcher/SteamExecutableNotFoundException.cs new file mode 100644 index 000000000..1734edafe --- /dev/null +++ b/Services/Exceptions/Launcher/SteamExecutableNotFoundException.cs @@ -0,0 +1,11 @@ +using System; + +namespace Services.Exceptions.Launcher +{ + public class SteamExecutableNotFoundException : Exception + { + public SteamExecutableNotFoundException() : base("Steam.exe not found") + { + } + } +} diff --git a/Services/MultilingualResources/Services.ar.xlf b/Services/MultilingualResources/Services.ar.xlf index b19c60c0c..fb01a9072 100644 --- a/Services/MultilingualResources/Services.ar.xlf +++ b/Services/MultilingualResources/Services.ar.xlf @@ -78,10 +78,6 @@ {0} thrown a smoke {0} thrown a smoke - - HLAE not found. Please install it by enabling it from settings. - HLAE not found. Please install it by enabling it from settings. - ..\resources\vdm\execute_command.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 ..\resources\vdm\execute_command.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 diff --git a/Services/MultilingualResources/Services.da.xlf b/Services/MultilingualResources/Services.da.xlf index bf52ab0a8..8e9b03f05 100644 --- a/Services/MultilingualResources/Services.da.xlf +++ b/Services/MultilingualResources/Services.da.xlf @@ -78,10 +78,6 @@ {0} thrown a smoke {0} kastede en røg granat - - HLAE not found. Please install it by enabling it from settings. - HLAE not found. Please install it by enabling it from settings. - ..\resources\vdm\execute_command.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 ..\resources\vdm\execute_command.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 diff --git a/Services/MultilingualResources/Services.de.xlf b/Services/MultilingualResources/Services.de.xlf index 00020bf81..d436ae3ef 100644 --- a/Services/MultilingualResources/Services.de.xlf +++ b/Services/MultilingualResources/Services.de.xlf @@ -78,10 +78,6 @@ {0} thrown a smoke {0} warf eine Smoke - - HLAE not found. Please install it by enabling it from settings. - HLAE not found. Please install it by enabling it from settings. - ..\resources\vdm\execute_command.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 ..\resources\vdm\execute_command.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 diff --git a/Services/MultilingualResources/Services.es.xlf b/Services/MultilingualResources/Services.es.xlf index f1a556bc7..8527d328b 100644 --- a/Services/MultilingualResources/Services.es.xlf +++ b/Services/MultilingualResources/Services.es.xlf @@ -78,10 +78,6 @@ {0} thrown a smoke {0} lanzó una granada de humo - - HLAE not found. Please install it by enabling it from settings. - HLAE no encontrado. Por favor instálalo activándolo desde la configuración. - ..\resources\vdm\execute_command.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 ..\resources\vdm\execute_command.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 diff --git a/Services/MultilingualResources/Services.fr.xlf b/Services/MultilingualResources/Services.fr.xlf index bcf213974..cb736c1e3 100644 --- a/Services/MultilingualResources/Services.fr.xlf +++ b/Services/MultilingualResources/Services.fr.xlf @@ -78,10 +78,6 @@ {0} thrown a smoke {0} a jetée une fumigène - - HLAE not found. Please install it by enabling it from settings. - HLAE introuvable. Veuillez l'installer en l'activant depuis les options. - ..\resources\vdm\execute_command.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 ..\resources\vdm\execute_command.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 diff --git a/Services/MultilingualResources/Services.hr.xlf b/Services/MultilingualResources/Services.hr.xlf index b31f79fc4..f2bd137d4 100644 --- a/Services/MultilingualResources/Services.hr.xlf +++ b/Services/MultilingualResources/Services.hr.xlf @@ -78,10 +78,6 @@ {0} thrown a smoke {0} thrown a smoke - - HLAE not found. Please install it by enabling it from settings. - HLAE not found. Please install it by enabling it from settings. - ..\resources\vdm\execute_command.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 ..\resources\vdm\execute_command.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 diff --git a/Services/MultilingualResources/Services.hu.xlf b/Services/MultilingualResources/Services.hu.xlf index 73623137b..e7bb7a8c5 100644 --- a/Services/MultilingualResources/Services.hu.xlf +++ b/Services/MultilingualResources/Services.hu.xlf @@ -78,10 +78,6 @@ {0} thrown a smoke {0} dobott egy füstöt - - HLAE not found. Please install it by enabling it from settings. - HLAE nem található. Kérem telepítse, úgy, hogy aktiválja a beállításokban. - ..\resources\vdm\execute_command.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 ..\resources\vdm\execute_command.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 diff --git a/Services/MultilingualResources/Services.it.xlf b/Services/MultilingualResources/Services.it.xlf index cb855f181..38fff365a 100644 --- a/Services/MultilingualResources/Services.it.xlf +++ b/Services/MultilingualResources/Services.it.xlf @@ -78,10 +78,6 @@ {0} thrown a smoke {0} thrown a smoke - - HLAE not found. Please install it by enabling it from settings. - HLAE not found. Please install it by enabling it from settings. - ..\resources\vdm\execute_command.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 ..\resources\vdm\execute_command.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 diff --git a/Services/MultilingualResources/Services.ja.xlf b/Services/MultilingualResources/Services.ja.xlf index 5489550af..93f0e16db 100644 --- a/Services/MultilingualResources/Services.ja.xlf +++ b/Services/MultilingualResources/Services.ja.xlf @@ -78,10 +78,6 @@ {0} thrown a smoke {0} thrown a smoke - - HLAE not found. Please install it by enabling it from settings. - HLAE not found. Please install it by enabling it from settings. - ..\resources\vdm\execute_command.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 ..\resources\vdm\execute_command.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 diff --git a/Services/MultilingualResources/Services.nl.xlf b/Services/MultilingualResources/Services.nl.xlf index 09f00f7dd..69b658cc5 100644 --- a/Services/MultilingualResources/Services.nl.xlf +++ b/Services/MultilingualResources/Services.nl.xlf @@ -86,10 +86,6 @@ ..\resources\vdm\execute_command.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 ..\resources\vdm\execute_command.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 - - HLAE not found. Please install it by enabling it from settings. - HLAE not found. Please install it by enabling it from settings. - ..\resources\vdm\main.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 ..\resources\vdm\main.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 diff --git a/Services/MultilingualResources/Services.pl.xlf b/Services/MultilingualResources/Services.pl.xlf index c29de39e6..94b433d18 100644 --- a/Services/MultilingualResources/Services.pl.xlf +++ b/Services/MultilingualResources/Services.pl.xlf @@ -78,10 +78,6 @@ {0} thrown a smoke {0} rzucił granat dymny - - HLAE not found. Please install it by enabling it from settings. - Nie znaleziono HLAE. Zainstaluj HLAE włączając go w ustawieniach. - ..\resources\vdm\execute_command.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 ..\resources\vdm\execute_command.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 diff --git a/Services/MultilingualResources/Services.pt-BR.xlf b/Services/MultilingualResources/Services.pt-BR.xlf index 6a1b86af9..dc34a82dc 100644 --- a/Services/MultilingualResources/Services.pt-BR.xlf +++ b/Services/MultilingualResources/Services.pt-BR.xlf @@ -78,10 +78,6 @@ {0} thrown a smoke {0} jogou uma smoke - - HLAE not found. Please install it by enabling it from settings. - HLAE não encontrado. Instale-o, permitindo as configurações. - ..\resources\vdm\execute_command.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 ..\resources\vdm\execute_command.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 diff --git a/Services/MultilingualResources/Services.pt.xlf b/Services/MultilingualResources/Services.pt.xlf index ca74bad0f..8d08584ac 100644 --- a/Services/MultilingualResources/Services.pt.xlf +++ b/Services/MultilingualResources/Services.pt.xlf @@ -78,10 +78,6 @@ {0} thrown a smoke {0} thrown a smoke - - HLAE not found. Please install it by enabling it from settings. - HLAE not found. Please install it by enabling it from settings. - ..\resources\vdm\execute_command.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 ..\resources\vdm\execute_command.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 diff --git a/Services/MultilingualResources/Services.ru.xlf b/Services/MultilingualResources/Services.ru.xlf index 140358270..90f4f2e2b 100644 --- a/Services/MultilingualResources/Services.ru.xlf +++ b/Services/MultilingualResources/Services.ru.xlf @@ -78,10 +78,6 @@ {0} thrown a smoke {0} thrown a smoke - - HLAE not found. Please install it by enabling it from settings. - HLAE not found. Please install it by enabling it from settings. - ..\resources\vdm\execute_command.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 ..\resources\vdm\execute_command.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 diff --git a/Services/MultilingualResources/Services.sr-Cyrl.xlf b/Services/MultilingualResources/Services.sr-Cyrl.xlf index 5946e71cc..53e648cdf 100644 --- a/Services/MultilingualResources/Services.sr-Cyrl.xlf +++ b/Services/MultilingualResources/Services.sr-Cyrl.xlf @@ -78,10 +78,6 @@ {0} thrown a smoke {0} thrown a smoke - - HLAE not found. Please install it by enabling it from settings. - HLAE not found. Please install it by enabling it from settings. - ..\resources\vdm\execute_command.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 ..\resources\vdm\execute_command.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 diff --git a/Services/MultilingualResources/Services.tr-TR.xlf b/Services/MultilingualResources/Services.tr-TR.xlf index f4298af21..5f2bd2b25 100644 --- a/Services/MultilingualResources/Services.tr-TR.xlf +++ b/Services/MultilingualResources/Services.tr-TR.xlf @@ -86,10 +86,6 @@ ..\resources\vdm\execute_command.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 ..\resources\vdm\execute_command.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 - - HLAE not found. Please install it by enabling it from settings. - HLAE not found. Please install it by enabling it from settings. - ..\resources\vdm\main.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 ..\resources\vdm\main.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 diff --git a/Services/MultilingualResources/Services.tr.xlf b/Services/MultilingualResources/Services.tr.xlf index 4a6994c20..dab7b5394 100644 --- a/Services/MultilingualResources/Services.tr.xlf +++ b/Services/MultilingualResources/Services.tr.xlf @@ -78,10 +78,6 @@ {0} thrown a smoke {0} thrown a smoke - - HLAE not found. Please install it by enabling it from settings. - HLAE not found. Please install it by enabling it from settings. - ..\resources\vdm\execute_command.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 ..\resources\vdm\execute_command.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 diff --git a/Services/MultilingualResources/Services.zh-Hans.xlf b/Services/MultilingualResources/Services.zh-Hans.xlf index cd4194da6..bcb9a746b 100644 --- a/Services/MultilingualResources/Services.zh-Hans.xlf +++ b/Services/MultilingualResources/Services.zh-Hans.xlf @@ -78,10 +78,6 @@ {0} thrown a smoke {0} 投掷了一个烟雾弹 - - HLAE not found. Please install it by enabling it from settings. - 无法找到HLAE引擎,请安装后在设置中启用. - ..\resources\vdm\execute_command.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 ..\resources\vdm\execute_command.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 @@ -182,4 +178,4 @@ - + \ No newline at end of file diff --git a/Services/MultilingualResources/Services.zh-Hant.xlf b/Services/MultilingualResources/Services.zh-Hant.xlf index 30e40b2d9..3573ea228 100644 --- a/Services/MultilingualResources/Services.zh-Hant.xlf +++ b/Services/MultilingualResources/Services.zh-Hant.xlf @@ -78,10 +78,6 @@ {0} thrown a smoke {0} thrown a smoke - - HLAE not found. Please install it by enabling it from settings. - HLAE not found. Please install it by enabling it from settings. - ..\resources\vdm\execute_command.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 ..\resources\vdm\execute_command.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 diff --git a/Services/Properties/Resources.Designer.cs b/Services/Properties/Resources.Designer.cs index bd733fd26..fb309fc6c 100644 --- a/Services/Properties/Resources.Designer.cs +++ b/Services/Properties/Resources.Designer.cs @@ -19,7 +19,7 @@ namespace Services.Properties { // class via a tool like ResGen or Visual Studio. // To add or remove a member, edit your .ResX file then rerun ResGen // with the /str option, or rebuild your VS project. - [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "16.0.0.0")] + [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "17.0.0.0")] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] public class Resources { @@ -184,15 +184,6 @@ public static string HEEventName { } } - /// - /// Looks up a localized string similar to HLAE not found. Please install it by enabling it from settings.. - /// - public static string HlaeNotFoundException { - get { - return ResourceManager.GetString("HlaeNotFoundException", resourceCulture); - } - } - /// /// Looks up a localized string similar to Incendiary. /// diff --git a/Services/Properties/Resources.es.resx b/Services/Properties/Resources.es.resx index cb8a2ef24..8f9996070 100644 --- a/Services/Properties/Resources.es.resx +++ b/Services/Properties/Resources.es.resx @@ -60,9 +60,6 @@ {0} lanzó una granada de humo - - HLAE no encontrado. Por favor instálalo activándolo desde la configuración. - ..\resources\vdm\spec_player_lock.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 diff --git a/Services/Properties/Resources.fr.resx b/Services/Properties/Resources.fr.resx index e35426ef3..2f97e5aff 100644 --- a/Services/Properties/Resources.fr.resx +++ b/Services/Properties/Resources.fr.resx @@ -60,9 +60,6 @@ {0} a jetée une fumigène - - HLAE introuvable. Veuillez l'installer en l'activant depuis les options. - Victime diff --git a/Services/Properties/Resources.hu.resx b/Services/Properties/Resources.hu.resx index b74a86045..f296883d7 100644 --- a/Services/Properties/Resources.hu.resx +++ b/Services/Properties/Resources.hu.resx @@ -60,9 +60,6 @@ {0} dobott egy füstöt - - HLAE nem található. Kérem telepítse, úgy, hogy aktiválja a beállításokban. - ..\resources\vdm\spec_player_lock.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 diff --git a/Services/Properties/Resources.pl.resx b/Services/Properties/Resources.pl.resx index eeb9c8761..5611bcd07 100644 --- a/Services/Properties/Resources.pl.resx +++ b/Services/Properties/Resources.pl.resx @@ -60,9 +60,6 @@ {0} rzucił granat dymny - - Nie znaleziono HLAE. Zainstaluj HLAE włączając go w ustawieniach. - ..\resources\vdm\spec_player_lock.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 diff --git a/Services/Properties/Resources.pt-BR.resx b/Services/Properties/Resources.pt-BR.resx index ae8a0334c..12f0cb5fa 100644 --- a/Services/Properties/Resources.pt-BR.resx +++ b/Services/Properties/Resources.pt-BR.resx @@ -66,9 +66,6 @@ {0} jogou uma smoke - - HLAE não encontrado. Instale-o, permitindo as configurações. - ..\resources\vdm\spec_player_lock.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 diff --git a/Services/Properties/Resources.resx b/Services/Properties/Resources.resx index c7d367833..9b32209c9 100644 --- a/Services/Properties/Resources.resx +++ b/Services/Properties/Resources.resx @@ -178,9 +178,6 @@ ..\resources\vdm\execute_command.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 - - HLAE not found. Please install it by enabling it from settings. - ..\resources\vdm\main.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 diff --git a/Services/Properties/Resources.zh-Hans.resx b/Services/Properties/Resources.zh-Hans.resx index a9aafd2a1..8dd44a51d 100644 --- a/Services/Properties/Resources.zh-Hans.resx +++ b/Services/Properties/Resources.zh-Hans.resx @@ -60,9 +60,6 @@ {0} 投掷了一个烟雾弹 - - 无法找到HLAE引擎,请安装后在设置中启用. - 击杀 diff --git a/Services/Services.csproj b/Services/Services.csproj index 081bd010a..288373753 100644 --- a/Services/Services.csproj +++ b/Services/Services.csproj @@ -180,6 +180,9 @@ + + +