diff --git a/EndlessClient/GameExecution/ReleaseGameRunner.cs b/EndlessClient/GameExecution/ReleaseGameRunner.cs index 13a983be6..456ad381d 100644 --- a/EndlessClient/GameExecution/ReleaseGameRunner.cs +++ b/EndlessClient/GameExecution/ReleaseGameRunner.cs @@ -1,4 +1,6 @@ using System; +using System.Runtime.InteropServices; +using System.Runtime.Versioning; #if !LINUX using System.Windows.Forms; #endif @@ -28,6 +30,8 @@ public override bool SetupDependencies() "Dependency setup error!", MessageBoxButtons.OK, MessageBoxIcon.Error); +#else + throw; #endif return false; } @@ -42,12 +46,18 @@ public override void RunGame() catch (Exception ex) { #if !LINUX - ShowExceptionDialog(ex); + if (RuntimeInformation.IsOSPlatform(OSPlatform.Windows)) + ShowExceptionDialog(ex); + else + throw; +#else + throw; #endif } } #if !LINUX + [SupportedOSPlatform("Windows")] private static void ShowExceptionDialog(Exception ex) { Application.EnableVisualStyles();