fixed crash on launch during debugging

This commit is contained in:
WeeXnes 2023-10-07 16:03:45 +02:00
parent 336dbef991
commit e3a34fa966
4 changed files with 12 additions and 11 deletions

View file

@ -127,12 +127,12 @@ namespace WeeXnes
{ {
Game newGame = Game.Methods.GameFromIni(new INIFile(file.FullName)); Game newGame = Game.Methods.GameFromIni(new INIFile(file.FullName));
DiscordRPCView.Data.Games.Add(newGame); DiscordRPCView.Data.Games.Add(newGame);
WeeXnes.Core.CustomConsole.WriteLine(file.Name + " loaded"); WeeXnes.Core.CustomConsole.WriteLine(file.Name + " loaded -> " + newGame.ProcessName);
} }
catch (Exception ex) catch (Exception ex)
{ {
WeeXnes.Core.CustomConsole.Error(file.Name + ": " + ex.Message); WeeXnes.Core.CustomConsole.Error(file.Name + ": " + ex.Message);
MessageBox.Show(file.Name + ": " + ex.Message); new FluentMessageBox(file.Name + ": " + ex.Message).ShowDialog();
} }
} }
Functions.CheckFolderAndCreate(Global.AppDataPathKEY.Value); Functions.CheckFolderAndCreate(Global.AppDataPathKEY.Value);
@ -153,12 +153,13 @@ namespace WeeXnes
); );
newItem.Filename = file.Name; newItem.Filename = file.Name;
KeyManagerView.Data.KeyItemsList.Add(newItem); KeyManagerView.Data.KeyItemsList.Add(newItem);
WeeXnes.Core.CustomConsole.WriteLine(file.Name + " loaded"); WeeXnes.Core.CustomConsole.WriteLine(file.Name + " loaded -> " + newItem.Name);
} }
catch (Exception ex) catch (Exception ex)
{ {
WeeXnes.Core.CustomConsole.Error(file.Name + ": " + ex.Message); WeeXnes.Core.CustomConsole.Error(file.Name + ": " + ex.Message);
new FluentMessageBox(file.Name + ": " + ex.Message).ShowDialog();
} }
} }
} }

View file

@ -21,11 +21,11 @@ namespace WeeXnes.Core
public static class Formatting public static class Formatting
{ {
public static string success_char = ""; public static string success_char = "";
public static string warning_char = ""; public static string warning_char = "";
public static string info_char = ""; public static string info_char = "";
public static string error_char = ""; public static string error_char = "";
public static string writeline_char = ""; public static string writeline_char = "";
} }
} }
@ -37,7 +37,7 @@ namespace WeeXnes.Core
if(!App.DebugMode) if(!App.DebugMode)
return; return;
VanillaConsole.OutputEncoding = Encoding.UTF8; //VanillaConsole.OutputEncoding = Encoding.UTF8;
ConsoleColor prevColor = VanillaConsole.BackgroundColor; ConsoleColor prevColor = VanillaConsole.BackgroundColor;
ConsoleColor prevForeColor = VanillaConsole.ForegroundColor; ConsoleColor prevForeColor = VanillaConsole.ForegroundColor;

View file

@ -8,7 +8,7 @@ namespace WeeXnes.Core
{ {
public class Information public class Information
{ {
public const string Version = "4.4.5"; public const string Version = "4.4.6";
public const string EncryptionHash = "8zf5#RdyQ]$4x4_"; public const string EncryptionHash = "8zf5#RdyQ]$4x4_";
public const string ApiUrl = "https://api.github.com/repos/weexnes/weexnessuite/releases/latest"; public const string ApiUrl = "https://api.github.com/repos/weexnes/weexnessuite/releases/latest";
} }

View file

@ -4,7 +4,7 @@
<PropertyGroup> <PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration> <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform> <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<Version>4.4.5</Version> <Version>4.4.6</Version>
<ProjectGuid>{4B33CEE7-C74D-43B9-B99A-8B273D5195BC}</ProjectGuid> <ProjectGuid>{4B33CEE7-C74D-43B9-B99A-8B273D5195BC}</ProjectGuid>
<OutputType>WinExe</OutputType> <OutputType>WinExe</OutputType>
<RootNamespace>WeeXnes</RootNamespace> <RootNamespace>WeeXnes</RootNamespace>