From 20ba9c53ec49ebd4c000023807a90eff05f2afd7 Mon Sep 17 00:00:00 2001 From: Shadow Eevee Date: Sun, 8 Mar 2020 11:17:24 -0700 Subject: [PATCH] Fixed mislabled exit codes Fixed mislabled exit codes (Exit Codes were 1601 to 1628, needed 16001 to 16028 to prevent OS exit code interferance.) --- Sharpii/BNS.cs | 8 +++--- Sharpii/EXT.cs | 60 +++++++++++++++++++++--------------------- Sharpii/Exit Codes.txt | 56 +++++++++++++++++++-------------------- Sharpii/HBC.cs | 26 +++++++++--------- Sharpii/IOS.cs | 24 ++++++++--------- Sharpii/NUSD.cs | 32 +++++++++++----------- Sharpii/Program.cs | 10 +++---- Sharpii/TPL.cs | 16 +++++------ Sharpii/U8.cs | 14 +++++----- Sharpii/WAD.cs | 52 ++++++++++++++++++------------------ 10 files changed, 149 insertions(+), 149 deletions(-) diff --git a/Sharpii/BNS.cs b/Sharpii/BNS.cs index ef663f7..b4e415c 100644 --- a/Sharpii/BNS.cs +++ b/Sharpii/BNS.cs @@ -58,7 +58,7 @@ namespace Sharpii Console.WriteLine("ERROR: Unable to open file: {0}", input); Console.WriteLine("Either the file doesn't exist, or Sharpii doesn't have permission to open it."); Console.WriteLine("Error: SHARPII_NET_CORE_BNS_FILE_ERR_01"); - Environment.Exit(0x00000641); + Environment.Exit(0x00003E81); return; } @@ -94,7 +94,7 @@ namespace Sharpii Console.WriteLine(""); Console.WriteLine("ERROR DETAILS: {0}", ex.Message); Console.WriteLine("Error: SHARPII_NET_CORE_BNS_UNKNOWN_01"); - Environment.Exit(0x00000642); + Environment.Exit(0x00003E82); return; } } @@ -112,7 +112,7 @@ namespace Sharpii Console.WriteLine("ERROR: Unable to open file: {0}", input); Console.WriteLine("Either the file doesn't exist, or Sharpii doesn't have permission to open it."); Console.WriteLine("Error: SHARPII_NET_CORE_BNS_FILE_ERR_01"); - Environment.Exit(0x00000641); + Environment.Exit(0x00003E81); return; } @@ -181,7 +181,7 @@ namespace Sharpii Console.WriteLine(""); Console.WriteLine("ERROR DETAILS: {0}", ex.Message); Console.WriteLine("Error: SHARPII_NET_CORE_BNS_UNKNOWN_01"); - Environment.Exit(0x00000642); + Environment.Exit(0x00003E82); return; } } diff --git a/Sharpii/EXT.cs b/Sharpii/EXT.cs index a086e9b..1941314 100644 --- a/Sharpii/EXT.cs +++ b/Sharpii/EXT.cs @@ -59,7 +59,7 @@ namespace Sharpii ErrCodeFound = 1; } - if (args[1] == "1603") + if (args[1] == "16003") { Console.WriteLine(""); Console.WriteLine("No IP was provided for remote Wii access. (SHARPII_NET_CORE_HBC_NO_IP_01)"); @@ -70,7 +70,7 @@ namespace Sharpii Console.WriteLine(""); ErrCodeFound = 1; } - if (args[1] == "1604") + if (args[1] == "16004") { Console.WriteLine("DOL Flag was used, but no file provided. (SHARPII_NET_CORE_xxx_NO_DOL_01)"); Console.WriteLine("You used the -DOL flag, but no DOL file was provided."); @@ -80,7 +80,7 @@ namespace Sharpii Console.WriteLine(""); ErrCodeFound = 1; } - if (args[1] == "1605") + if (args[1] == "16005") { Console.WriteLine(""); Console.WriteLine("A Critical DLL (WadInstaller.dll) couldn't be found. (SHARPII_NET_CORE_HBC_MISSING_DLL_WADINSTALLER_01)"); @@ -91,7 +91,7 @@ namespace Sharpii Console.WriteLine(""); ErrCodeFound = 1; } - if (args[1] == "1606") + if (args[1] == "16006") { Console.WriteLine(""); Console.WriteLine("IOS Flag was used, but no IOS provided. (SHARPII_NET_CORE_xxx_NO_IOS_01)"); @@ -102,7 +102,7 @@ namespace Sharpii Console.WriteLine(""); ErrCodeFound = 1; } - if (args[1] == "1607") + if (args[1] == "16007") { Console.WriteLine(""); Console.WriteLine("IOS Flag was used, but an invalid IOS provided. (SHARPII_NET_CORE_xxx_INVALID_IOS_01)"); @@ -113,7 +113,7 @@ namespace Sharpii Console.WriteLine(""); ErrCodeFound = 1; } - if (args[1] == "1608") + if (args[1] == "16008") { Console.WriteLine(""); Console.WriteLine("WAD Flag was used, but no wad provided. (SHARPII_NET_CORE_HBC_NO_WAD_01)"); @@ -124,7 +124,7 @@ namespace Sharpii Console.WriteLine(""); ErrCodeFound = 1; } - if (args[1] == "1609") + if (args[1] == "16009") { Console.WriteLine(""); Console.WriteLine("Slot Flag was used, but no slot provided. (SHARPII_NET_CORE_IOS_NO_SLOT_01)"); @@ -135,7 +135,7 @@ namespace Sharpii Console.WriteLine(""); ErrCodeFound = 1; } - if (args[1] == "1610") + if (args[1] == "16010") { Console.WriteLine(""); Console.WriteLine("Slot Flag was used, but an invalid slot provided. (SHARPII_NET_CORE_xxx_INVALID_SLOT_01)"); @@ -146,7 +146,7 @@ namespace Sharpii Console.WriteLine(""); ErrCodeFound = 1; } - if (args[1] == "1611") + if (args[1] == "16011") { Console.WriteLine(""); Console.WriteLine("V Flag was used, but no version provided. (SHARPII_NET_CORE_xxx_NO_VERSION_01)"); @@ -157,7 +157,7 @@ namespace Sharpii Console.WriteLine(""); ErrCodeFound = 1; } - if (args[1] == "1612") + if (args[1] == "16012") { Console.WriteLine(""); Console.WriteLine("V Flag was used, but an invalid version provided. (SHARPII_NET_CORE_xxx_INVALID_VERSION_01)"); @@ -168,7 +168,7 @@ namespace Sharpii Console.WriteLine(""); ErrCodeFound = 1; } - if (args[1] == "1613") + if (args[1] == "16013") { Console.WriteLine(""); Console.WriteLine("O Flag was used, but no output provided. (SHARPII_NET_CORE_xxx_NO_OUTPUT_01)"); @@ -179,7 +179,7 @@ namespace Sharpii Console.WriteLine(""); ErrCodeFound = 1; } - if (args[1] == "1614") + if (args[1] == "16014") { Console.WriteLine(""); Console.WriteLine("ID Flag was used, but no id provided. (SHARPII_NET_CORE_xxx_NO_ID_01)"); @@ -190,7 +190,7 @@ namespace Sharpii Console.WriteLine(""); ErrCodeFound = 1; } - if (args[1] == "1615") + if (args[1] == "16015") { Console.WriteLine(""); Console.WriteLine("A Critical DLL (libWiiSharp.dll) couldn't be found. (SHARPII_NET_CORE_HBC_MISSING_DLL_LIBWIISHARP_01)"); @@ -201,7 +201,7 @@ namespace Sharpii Console.WriteLine(""); ErrCodeFound = 1; } - if (args[1] == "1616") + if (args[1] == "16016") { Console.WriteLine(""); Console.WriteLine("An invalid argument was passed when starting Sharpii. (SHARPII_NET_CORE_xxx_INVALID_ARG_01)"); @@ -212,7 +212,7 @@ namespace Sharpii Console.WriteLine(""); ErrCodeFound = 1; } - if (args[1] == "1617") + if (args[1] == "16017") { Console.WriteLine(""); Console.WriteLine("FORMAT Flag was used, but no format provided. (SHARPII_NET_CORE_TPL_NO_FORMAT_01)"); @@ -223,7 +223,7 @@ namespace Sharpii Console.WriteLine(""); ErrCodeFound = 1; } - if (args[1] == "1618") + if (args[1] == "16018") { Console.WriteLine(""); Console.WriteLine("FORMAT Flag was used, but invalid format provided. (SHARPII_NET_CORE_TPL_INVALID_FORMAT_01)"); @@ -234,7 +234,7 @@ namespace Sharpii Console.WriteLine(""); ErrCodeFound = 1; } - if (args[1] == "1619") + if (args[1] == "16019") { Console.WriteLine(""); Console.WriteLine("A non U8 archive file was provided. (SHARPII_NET_CORE_U8_NON_U8_01)"); @@ -245,7 +245,7 @@ namespace Sharpii Console.WriteLine(""); ErrCodeFound = 1; } - if (args[1] == "1620") + if (args[1] == "16020") { Console.WriteLine(""); Console.WriteLine("Folder Access Issue/Missing Folder. (SHARPII_NET_CORE_xxx_FOLDER_ERR_01)"); @@ -256,7 +256,7 @@ namespace Sharpii Console.WriteLine(""); ErrCodeFound = 1; } - if (args[1] == "1621") + if (args[1] == "16021") { Console.WriteLine(""); Console.WriteLine("IMET Flag was used, but no title provided. (SHARPII_NET_CORE_xxx_NO_TITLE_01"); @@ -267,7 +267,7 @@ namespace Sharpii Console.WriteLine(""); ErrCodeFound = 1; } - if (args[1] == "1622") + if (args[1] == "16022") { Console.WriteLine(""); Console.WriteLine("IMET and IMD5 Flags were used, but only one can be used. (SHARPII_NET_CORE_U8_TWO_HEADERS"); @@ -278,7 +278,7 @@ namespace Sharpii Console.WriteLine(""); ErrCodeFound = 1; } - if (args[1] == "1623") + if (args[1] == "16023") { Console.WriteLine(""); Console.WriteLine("ID Flag was used, but short ID provided. (SHARPII_NET_CORE_WAD_SHORT_ID_01)"); @@ -289,7 +289,7 @@ namespace Sharpii Console.WriteLine(""); ErrCodeFound = 1; } - if (args[1] == "1624") + if (args[1] == "16024") { Console.WriteLine(""); Console.WriteLine("TYPE or IOS Flag used, but no type provided. (SHARPII_NET_CORE_WAD_NO_TYPE_01)"); @@ -300,7 +300,7 @@ namespace Sharpii Console.WriteLine(""); ErrCodeFound = 1; } - if (args[1] == "1625") + if (args[1] == "16025") { Console.WriteLine(""); Console.WriteLine("TYPE or IOS Flag used, but provided type unknown. (SHARPII_NET_CORE_WAD_UNKNOWN_TYPE_01)"); @@ -311,7 +311,7 @@ namespace Sharpii Console.WriteLine(""); ErrCodeFound = 1; } - if (args[1] == "1626") + if (args[1] == "16026") { Console.WriteLine(""); Console.WriteLine("SOUND Flag used, but no wad provided. (SHARPII_NET_CORE_WAD_NO_SOUND)"); @@ -322,7 +322,7 @@ namespace Sharpii Console.WriteLine(""); ErrCodeFound = 1; } - if (args[1] == "1627") + if (args[1] == "16027") { Console.WriteLine(""); Console.WriteLine("BANNER Flag used, but no wad provided. (SHARPII_NET_CORE_WAD_NO_BANNER)"); @@ -333,11 +333,7 @@ namespace Sharpii Console.WriteLine(""); ErrCodeFound = 1; } - if (ErrCodeFound != 1) - { - ExitCode_help(); - } - if (args[1] == "1628") + if (args[1] == "16028") { Console.WriteLine(""); Console.WriteLine("ID Flag was used, but invalid id provided. (SHARPII_NET_CORE_xxx_BAD_ID_01)"); @@ -348,6 +344,10 @@ namespace Sharpii Console.WriteLine(""); ErrCodeFound = 1; } + if (ErrCodeFound != 1) + { + ExitCode_help(); + } } catch (Exception) { diff --git a/Sharpii/Exit Codes.txt b/Sharpii/Exit Codes.txt index fb6eff2..e5d0894 100644 --- a/Sharpii/Exit Codes.txt +++ b/Sharpii/Exit Codes.txt @@ -2,145 +2,145 @@ Exit Code: 0 No errors reported/Likely successful exit -Exit Code: 1601 +Exit Code: 16001 File Access Issue/Missing File. (SHARPII_NET_CORE_xxx_FILE_ERR_01) Either the file doesn't exist, or Sharpii doesn't have permission to open it. Check the file's permissions and that it's in the right place. -Exit Code: 1602 +Exit Code: 16002 Unknown Error/Untracked Error. (SHARPII_NET_CORE_xxx_UNKNOWN_01) An untracked error has occured. Use the error text to self-diagnose. -Exit Code: 1603 +Exit Code: 16003 No IP was provided for remote Wii access. (SHARPII_NET_CORE_HBC_NO_IP_01) No IP address was listed for the Wii. Furthermore, no IP address is saved from previous uses. If this doesn't help, open an issue on GitHub! -Exit Code: 1604 +Exit Code: 16004 DOL Flag was used, but no file provided. (SHARPII_NET_CORE_xxx_NO_DOL_01) You used the -DOL flag, but no DOL file was provided. Provide the proper DOL file. -Exit Code: 1605 +Exit Code: 16005 A Critical DLL (WadInstaller.dll) couldn't be found. (SHARPII_NET_CORE_HBC_MISSING_DLL_WADINSTALLER_01) The WadInstaller.dll couldn't be found. This error SHOULD NOT APPEAR in this Sharpii port. Open an issue on GitHub! -Exit Code: 1606 +Exit Code: 16006 IOS Flag was used, but no IOS provided. (SHARPII_NET_CORE_xxx_NO_IOS_01) You used the -IOS flag, but no IOS was provided. Provide a proper IOS. -Exit Code: 1607 +Exit Code: 16007 IOS Flag was used, but an invalid IOS provided. (SHARPII_NET_CORE_xxx_INVALID_IOS_01) You used the -IOS flag, but an invalid IOS was provided. Provide a proper IOS. -Exit Code: 1608 +Exit Code: 16008 WAD Flag was used, but no wad provided. (SHARPII_NET_CORE_HBC_NO_WAD_01) You used the -WAD flag, but no WAD was provided. Provide a proper WAD. -Exit Code: 1609 +Exit Code: 16009 Slot Flag was used, but no slot provided. (SHARPII_NET_CORE_IOS_NO_SLOT_01) You used the -SLOT flag, but no slot was provided. Provide a proper slot. -Exit Code: 1610 +Exit Code: 16010 Slot Flag was used, but an invalid slot provided. (SHARPII_NET_CORE_xxx_INVALID_SLOT_01) You used the -SLOT flag, but an invalid slot was provided. Provide a proper slot. -Exit Code: 1611 +Exit Code: 16011 V Flag was used, but no version provided. (SHARPII_NET_CORE_xxx_NO_VERSION_01) You used the -V flag, but no version was provided. Provide a proper version. -Exit Code: 1612 +Exit Code: 16012 V Flag was used, but an invalid version provided. (SHARPII_NET_CORE_xxx_INVALID_VERSION_01) You used the -V flag, but no version was provided. Provide a proper version. -Exit Code: 1613 +Exit Code: 16013 O Flag was used, but no output provided. (SHARPII_NET_CORE_xxx_NO_OUTPUT_01) You used the -O flag, but no output was provided. Provide a proper output. -Exit Code: 1614 +Exit Code: 16014 ID Flag was used, but no id provided. (SHARPII_NET_CORE_xxx_NO_ID_01) You used the -ID flag, but no id was provided. Provide a proper id. -Exit Code: 1615 +Exit Code: 16015 A Critical DLL (libWiiSharp.dll) couldn't be found. (SHARPII_NET_CORE_MAIN_MISSING_DLL_LIBWIISHARP_01) The libWiiSharp.dll couldn't be found. This error SHOULD NOT APPEAR in this Sharpii port. Open an issue on GitHub! -Exit Code: 1616 +Exit Code: 16016 An invalid argument was passed when starting Sharpii. (SHARPII_NET_CORE_xxx_INVALID_ARG_01) An invalid argument was provided. Check the options you are using to start Sharpii. -Exit Code: 1617 +Exit Code: 16017 FORMAT Flag was used, but no format provided. (SHARPII_NET_CORE_TPL_NO_FORMAT_01) You used the -FORMAT flag, but no format was provided. Provide a proper format. -Exit Code: 1618 +Exit Code: 16018 FORMAT Flag was used, but invalid format provided. (SHARPII_NET_CORE_TPL_INVALID_FORMAT_01) You used the -FORMAT flag, but an invalid format was provided. Provide a proper format. -Exit Code: 1619 +Exit Code: 16019 A non U8 archive file was provided. (SHARPII_NET_CORE_U8_NON_U8_01) The provided file is not a U8 archive. Provide a U8 archive. -Exit Code: 1620 +Exit Code: 16020 Folder Access Issue/Missing Folder. (SHARPII_NET_CORE_xxx_FOLDER_ERR_01) Either the folder doesn't exist, or Sharpii doesn't have permission to open it. Check the folders's permissions and that it's in the right place. -Exit Code: 1621 +Exit Code: 16021 IMET Flag was used, but no title provided. (SHARPII_NET_CORE_xxx_NO_TITLE_01 You used the -IMET flag, but no title was provided. Provide a proper title. -Exit Code: 1622 +Exit Code: 16022 IMET and IMD5 Flags were used, but only one can be used. (SHARPII_NET_CORE_U8_TWO_HEADERS You used the -IMET and -IMD5 flags, but you can't use two headers. Provide only one flag. -Exit Code: 1623 +Exit Code: 16023 ID Flag was used, but short ID provided. (SHARPII_NET_CORE_WAD_SHORT_ID_01) You used the -ID flag, but the provided id was too short to be correct. Provide a proper id. -Exit Code: 1624 +Exit Code: 16024 TYPE or IOS Flag used, but no type provided. (SHARPII_NET_CORE_WAD_NO_TYPE_01) You used the -TYPE or -IOS flag, but no type was provided. Provide a proper type. -Exit Code: 1625 +Exit Code: 16025 TYPE or IOS Flag used, but provided type unknown. (SHARPII_NET_CORE_WAD_UNKNOWN_TYPE_01) You used the -TYPE flag, but an unknown type was provided. Provide a proper type. -Exit Code: 1626 +Exit Code: 16026 SOUND Flag used, but no wad provided. (SHARPII_NET_CORE_WAD_NO_SOUND) You used the -SOUND flag, but no wad file to provide sound was provided. Provide a proper wad. -Exit Code: 1627 +Exit Code: 16027 BANNER Flag used, but no wad provided. (SHARPII_NET_CORE_WAD_NO_BANNER) You used the BANNER flag, but no wad file to provide a banner was provided. Provide a proper wad. -Exit Code: 1618 +Exit Code: 16028 ID Flag was used, but invalid id provided. (SHARPII_NET_CORE_xxx_BAD_ID_01) You used the -ID flag, but an invalid id was provided. Provide a proper id. \ No newline at end of file diff --git a/Sharpii/HBC.cs b/Sharpii/HBC.cs index 0ac4932..732a54c 100644 --- a/Sharpii/HBC.cs +++ b/Sharpii/HBC.cs @@ -54,7 +54,7 @@ namespace Sharpii { Console.WriteLine("ERROR: No ip set"); Console.WriteLine("Error: SHARPII_NET_CORE_HBC_NO_IP_01"); - Environment.Exit(0x00000643); + Environment.Exit(0x00003E83); return; } ip = args[i + 1]; @@ -68,7 +68,7 @@ namespace Sharpii { Console.WriteLine("ERROR: No dol set"); Console.WriteLine("Error: SHARPII_NET_CORE_HBC_NO_DOL_01"); - Environment.Exit(0x00000644); + Environment.Exit(0x00003E84); return; } input = args[i + 1]; @@ -78,7 +78,7 @@ namespace Sharpii Console.WriteLine("ERROR: Unable to open file: {0}", input); Console.WriteLine("Either the file doesn't exist, or Sharpii doesn't have permission to open it."); Console.WriteLine("Error: SHARPII_NET_CORE_HBC_FILE_ERR_01"); - Environment.Exit(0x00000641); + Environment.Exit(0x00003E81); return; } @@ -118,7 +118,7 @@ namespace Sharpii { Console.WriteLine("ERROR: No IP set"); Console.WriteLine("Error: SHARPII_NET_CORE_HBC_NO_IP_01"); - Environment.Exit(0x00000643); + Environment.Exit(0x00003E83); return; } if (noip == true && BeQuiet.quiet > 2) @@ -163,7 +163,7 @@ namespace Sharpii Console.WriteLine(""); Console.WriteLine("ERROR DETAILS: {0}", ex.Message); Console.WriteLine("Error: SHARPII_NET_CORE_HBC_UNKNOWN_01"); - Environment.Exit(0x00000642); + Environment.Exit(0x00003E82); return; } @@ -190,7 +190,7 @@ namespace Sharpii Console.WriteLine("This should not appear on the .Net Core port."); Console.WriteLine("If you see this, report how you got here on https://github.com/TheShadowEevee/Sharpii-NetCore/issues."); Console.WriteLine("Error: SHARPII_NET_CORE_HBC_MISSING_DLL_WADINSTALLER_01"); - Environment.Exit(0x00000645); + Environment.Exit(0x00003E85); } return true; @@ -216,7 +216,7 @@ namespace Sharpii { Console.WriteLine("ERROR: No ios set"); Console.WriteLine("Error: SHARPII_NET_CORE_HBC_NO_IOS_01"); - Environment.Exit(0x00000646); + Environment.Exit(0x00003E86); return; } ios = args[i + 1]; @@ -224,7 +224,7 @@ namespace Sharpii { Console.WriteLine("ERROR: Invalid IOS number"); Console.WriteLine("Error: SHARPII_NET_CORE_HBC_INVALID_IOS_01"); - Environment.Exit(0x00000647); + Environment.Exit(0x00003E87); return; } break; @@ -236,7 +236,7 @@ namespace Sharpii { Console.WriteLine("ERROR: No ip set"); Console.WriteLine("Error: SHARPII_NET_CORE_HBC_NO_IP_01"); - Environment.Exit(0x00000643); + Environment.Exit(0x00003E83); return; } ip = args[i + 1]; @@ -250,7 +250,7 @@ namespace Sharpii { Console.WriteLine("ERROR: No WAD set"); Console.WriteLine("Error: SHARPII_NET_CORE_HBC_NO_WAD_01"); - Environment.Exit(0x00000648); + Environment.Exit(0x00003E88); return; } input = args[i + 1]; @@ -259,7 +259,7 @@ namespace Sharpii { Console.WriteLine("ERROR: Unable to open file: {0}", input); Console.WriteLine("Error: SHARPII_NET_CORE_BNS_FILE_ERR_01"); - Environment.Exit(0x00000641); + Environment.Exit(0x00003E81); return; } break; @@ -294,7 +294,7 @@ namespace Sharpii { Console.WriteLine("ERROR: No IP set"); Console.WriteLine("Error: SHARPII_NET_CORE_HBC_NO_IP_01"); - Environment.Exit(0x00000643); + Environment.Exit(0x00003E83); return; } if (noip == true && BeQuiet.quiet > 2) @@ -331,7 +331,7 @@ namespace Sharpii Console.WriteLine(""); Console.WriteLine("ERROR DETAILS: {0}", ex.Message); Console.WriteLine("Error: SHARPII_NET_CORE_HBC_UNKNOWN_01"); - Environment.Exit(0x00000642); + Environment.Exit(0x00003E82); return; } diff --git a/Sharpii/IOS.cs b/Sharpii/IOS.cs index 3b3a62a..e9e6a78 100644 --- a/Sharpii/IOS.cs +++ b/Sharpii/IOS.cs @@ -45,7 +45,7 @@ namespace Sharpii Console.WriteLine("ERROR: Unable to open file: {0}", input); Console.WriteLine("Either the file doesn't exist, or Sharpii doesn't have permission to open it."); Console.WriteLine("Error: SHARPII_NET_CORE_IOS_FILE_ERR_01"); - Environment.Exit(0x00000641); + Environment.Exit(0x00003E81); return; } @@ -71,21 +71,21 @@ namespace Sharpii { Console.WriteLine("ERROR: No slot set"); Console.WriteLine("Error: SHARPII_NET_CORE_IOS_NO_SLOT_01"); - Environment.Exit(0x00000649); + Environment.Exit(0x00003E89); return; } if (!int.TryParse(args[i + 1], out slot)) { Console.WriteLine("Invalid slot {0}...", args[i + 1]); Console.WriteLine("Error: SHARPII_NET_CORE_IOS_INVALID_SLOT_01"); - Environment.Exit(0x0000064A); + Environment.Exit(0x00003E8A); return; } if (slot < 3 || slot > 255) { Console.WriteLine("Invalid slot {0}...", slot); Console.WriteLine("Error: SHARPII_NET_CORE_IOS_INVALID_SLOT_01"); - Environment.Exit(0x0000064A); + Environment.Exit(0x00003E8A); return; } break; @@ -94,21 +94,21 @@ namespace Sharpii { Console.WriteLine("ERROR: No slot set"); Console.WriteLine("Error: SHARPII_NET_CORE_IOS_NO_SLOT_01"); - Environment.Exit(0x00000649); + Environment.Exit(0x00003E89); return; } if (!int.TryParse(args[i + 1], out slot)) { Console.WriteLine("Invalid slot {0}...", args[i + 1]); Console.WriteLine("Error: SHARPII_NET_CORE_IOS_INVALID_SLOT_01"); - Environment.Exit(0x0000064A); + Environment.Exit(0x00003E8A); return; } if (slot < 3 || slot > 255) { Console.WriteLine("Invalid slot {0}...", slot); Console.WriteLine("Error: SHARPII_NET_CORE_IOS_INVALID_SLOT_01"); - Environment.Exit(0x0000064A); + Environment.Exit(0x00003E8A); return; } break; @@ -117,21 +117,21 @@ namespace Sharpii { Console.WriteLine("ERROR: No version set"); Console.WriteLine("Error: SHARPII_NET_CORE_IOS_NO_VERSION_01"); - Environment.Exit(0x0000064B); + Environment.Exit(0x00003E8B); return; } if (!int.TryParse(args[i + 1], out version)) { Console.WriteLine("Invalid version {0}...", args[i + 1]); Console.WriteLine("Error: SHARPII_NET_CORE_IOS_INVALID_VERSION_01"); - Environment.Exit(0x0000064C); + Environment.Exit(0x00003E8C); return; } if (version < 0 || version > 65535) { Console.WriteLine("Invalid version {0}...", version); Console.WriteLine("Error: SHARPII_NET_CORE_IOS_INVALID_VERSION_01"); - Environment.Exit(0x0000064C); + Environment.Exit(0x00003E8C); return; } break; @@ -140,7 +140,7 @@ namespace Sharpii { Console.WriteLine("ERROR: No output set"); Console.WriteLine("Error: SHARPII_NET_CORE_IOS_NO_OUTPUT_01"); - Environment.Exit(0x0000064D); + Environment.Exit(0x00003E8D); return; } output = args[i + 1]; @@ -251,7 +251,7 @@ namespace Sharpii Console.WriteLine(""); Console.WriteLine("ERROR DETAILS: {0}", ex.Message); Console.WriteLine("Error: SHARPII_NET_CORE_IOS_UNKNOWN_01"); - Environment.Exit(0x00000642); + Environment.Exit(0x00003E82); return; } diff --git a/Sharpii/NUSD.cs b/Sharpii/NUSD.cs index 32c64c8..ab458de 100644 --- a/Sharpii/NUSD.cs +++ b/Sharpii/NUSD.cs @@ -88,7 +88,7 @@ namespace Sharpii { Console.WriteLine("ERROR: No version set"); Console.WriteLine("Error: SHARPII_NET_CORE_NUSD_NO_VERSION_01"); - Environment.Exit(0x0000064B); + Environment.Exit(0x00003E8B); return; } version = args[i + 1]; @@ -98,14 +98,14 @@ namespace Sharpii { Console.WriteLine("Invalid version {0}...", args[i + 1]); Console.WriteLine("Error: SHARPII_NET_CORE_NUSD_INVALID_VERSION_01"); - Environment.Exit(0x0000064C); + Environment.Exit(0x00003E8C); return; } if (intver < 0 || intver > 65535) { Console.WriteLine("Invalid version {0}...", version); Console.WriteLine("Error: SHARPII_NET_CORE_NUSD_INVALID_VERSION_01"); - Environment.Exit(0x0000064C); + Environment.Exit(0x00003E8C); return; } break; @@ -114,7 +114,7 @@ namespace Sharpii { Console.WriteLine("ERROR: No version set"); Console.WriteLine("Error: SHARPII_NET_CORE_NUSD_NO_VERSION_01"); - Environment.Exit(0x0000064B); + Environment.Exit(0x00003E8B); return; } version = args[i + 1]; @@ -124,14 +124,14 @@ namespace Sharpii { Console.WriteLine("Invalid version {0}...", args[i + 1]); Console.WriteLine("Error: SHARPII_NET_CORE_NUSD_INVALID_VERSION_01"); - Environment.Exit(0x0000064C); + Environment.Exit(0x00003E8C); return; } if (intver < 0 || intver > 65535) { Console.WriteLine("Invalid version {0}...", version); Console.WriteLine("Error: SHARPII_NET_CORE_NUSD_INVALID_VERSION_01"); - Environment.Exit(0x0000064C); + Environment.Exit(0x00003E8C); return; } break; @@ -140,7 +140,7 @@ namespace Sharpii { Console.WriteLine("ERROR: No output set"); Console.WriteLine("Error: SHARPII_NET_CORE_NUSD_NO_OUTPUT_01"); - Environment.Exit(0x0000064D); + Environment.Exit(0x00003E8D); return; } output = args[i + 1]; @@ -150,7 +150,7 @@ namespace Sharpii { Console.WriteLine("ERROR: No ID specified"); Console.WriteLine("Error: SHARPII_NET_CORE_NUSD_NO_ID_01"); - Environment.Exit(0x0000064E); + Environment.Exit(0x00003E8E); return; } id = args[i + 1]; @@ -160,7 +160,7 @@ namespace Sharpii { Console.WriteLine("ERROR: No IOS specified"); Console.WriteLine("Error: SHARPII_NET_CORE_NUSD_NO_IOS_01"); - Environment.Exit(0x00000646); + Environment.Exit(0x00003E86); return; } id = "00000001000000" + Convert.ToInt32(args[i + 1]).ToString("X2"); @@ -170,7 +170,7 @@ namespace Sharpii { Console.WriteLine("ERROR: No ID specified"); Console.WriteLine("Error: SHARPII_NET_CORE_NUSD_NO_ID_01"); - Environment.Exit(0x0000064E); + Environment.Exit(0x00003E8E); return; } content = args[i + 1]; @@ -180,7 +180,7 @@ namespace Sharpii { Console.WriteLine("ERROR: No ID specified"); Console.WriteLine("Error: SHARPII_NET_CORE_NUSD_NO_ID_01"); - Environment.Exit(0x0000064E); + Environment.Exit(0x00003E8E); return; } content = args[i + 1]; @@ -193,7 +193,7 @@ namespace Sharpii { Console.WriteLine("ERROR: No ID specified"); Console.WriteLine("Error: SHARPII_NET_CORE_NUSD_NO_ID_01"); - Environment.Exit(0x0000064E); + Environment.Exit(0x00003E8E); return; } @@ -223,7 +223,7 @@ namespace Sharpii Console.WriteLine(""); Console.WriteLine("Error: SHARPII_NET_CORE_NUSD_BAD_ID_01"); Console.WriteLine(""); - Environment.Exit(0x0000065C); + Environment.Exit(0x00003E9C); return; } if (ex.Message == "The remote server returned an error: (404) Not Found.") @@ -233,7 +233,7 @@ namespace Sharpii Console.WriteLine(""); Console.WriteLine("Error: SHARPII_NET_CORE_NUSD_BAD_ID_01"); Console.WriteLine(""); - Environment.Exit(0x0000065C); + Environment.Exit(0x00003E9C); return; } } @@ -316,7 +316,7 @@ namespace Sharpii Console.WriteLine(""); Console.WriteLine("ERROR DETAILS: {0}", ex.Message); Console.WriteLine("Error: SHARPII_NET_CORE_NUSD_UNKNOWN_01"); - Environment.Exit(0x00000642); + Environment.Exit(0x00003E82); return; } @@ -333,7 +333,7 @@ namespace Sharpii Console.WriteLine("ERROR: Can't find WAD"); Console.WriteLine("Either the file doesn't exist, or Sharpii doesn't have permission to open it."); Console.WriteLine("Error: SHARPII_NET_CORE_NUSD_FILE_ERR_01"); - Environment.Exit(0x00000641); + Environment.Exit(0x00003E81); return; } if (ios != "" && NoOut == true) diff --git a/Sharpii/Program.cs b/Sharpii/Program.cs index 4623bf3..10998ed 100644 --- a/Sharpii/Program.cs +++ b/Sharpii/Program.cs @@ -39,7 +39,7 @@ namespace Sharpii Console.WriteLine("This should not appear on the .Net Core port."); Console.WriteLine("If you see this, report how you got here on https://github.com/TheShadowEevee/Sharpii-NetCore/issues."); Console.WriteLine("Error: SHARPII_NET_CORE_MAIN_MISSING_DLL_LIBWIISHARP_01"); - Environment.Exit(0x0000064F); + Environment.Exit(0x00003E8F); } for (int i = 1; i < args.Length; i++) @@ -157,7 +157,7 @@ namespace Sharpii //If tuser gets here, they entered something wrong Console.WriteLine("ERROR: The argument {0} is invalid", args[0]); Console.WriteLine("Error: SHARPII_NET_CORE_MAIN_INVALID_ARG_01"); - Environment.Exit(0x00000650); + Environment.Exit(0x00003E90); } string temp = Path.GetTempPath() + "Sharpii.tmp"; @@ -202,7 +202,7 @@ namespace Sharpii catch (Exception ex) { Console.WriteLine("An unknown error occured, please try again\n\nERROR DETAILS: {0}", ex.Message); - Environment.Exit(0x00000642); + Environment.Exit(0x00003E82); return; } } @@ -222,7 +222,7 @@ namespace Sharpii catch (Exception ex) { Console.WriteLine("An unknown error occured, please try again\n\nERROR DETAILS: {0}", ex.Message); - Environment.Exit(0x00000642); + Environment.Exit(0x00003E82); return; } } @@ -290,7 +290,7 @@ namespace Sharpii Console.WriteLine(" -lots Display lots of output"); Console.WriteLine(" -nolog Don't create a log file"); Console.WriteLine(""); - Environment.Exit(0x0000064E); + Environment.Exit(0x00003E8E); } } diff --git a/Sharpii/TPL.cs b/Sharpii/TPL.cs index 26a1255..787d3ab 100644 --- a/Sharpii/TPL.cs +++ b/Sharpii/TPL.cs @@ -48,7 +48,7 @@ namespace Sharpii //If tuser gets here, they entered something wrong Console.WriteLine("ERROR: The argument {0} is invalid", args[1]); Console.WriteLine("Error: SHARPII_NET_CORE_TPL_INVALID_ARG_01"); - Environment.Exit(0x00000650); + Environment.Exit(0x00003E90); return; } @@ -64,7 +64,7 @@ namespace Sharpii Console.WriteLine("ERROR: Unable to open file: {0}", input); Console.WriteLine("Either the file doesn't exist, or Sharpii doesn't have permission to open it."); Console.WriteLine("Error: SHARPII_NET_CORE_TPL_FILE_ERR_01"); - Environment.Exit(0x00000641); + Environment.Exit(0x00003E81); return; } @@ -98,7 +98,7 @@ namespace Sharpii Console.WriteLine(""); Console.WriteLine("ERROR DETAILS: {0}", ex.Message); Console.WriteLine("Error: SHARPII_NET_CORE_TPL_UNKNOWN_01"); - Environment.Exit(0x00000642); + Environment.Exit(0x00003E82); return; } } @@ -116,7 +116,7 @@ namespace Sharpii Console.WriteLine("ERROR: Unable to open file: {0}", input); Console.WriteLine("Either the file doesn't exist, or Sharpii doesn't have permission to open it."); Console.WriteLine("Error: SHARPII_NET_CORE_TPL_FILE_ERR_01"); - Environment.Exit(0x00000641); + Environment.Exit(0x00003E81); return; } @@ -130,7 +130,7 @@ namespace Sharpii { Console.WriteLine("ERROR: No format set"); Console.WriteLine("Error: SHARPII_NET_CORE_TPL_NO_FORMAT_01"); - Environment.Exit(0x00000651); + Environment.Exit(0x00003E91); return; } tplFormat = args[i + 1]; @@ -140,7 +140,7 @@ namespace Sharpii { Console.WriteLine("ERROR: No format set"); Console.WriteLine("Error: SHARPII_NET_CORE_TPL_NO_FORMAT_01"); - Environment.Exit(0x00000651); + Environment.Exit(0x00003E91); return; } tplFormat = args[i + 1]; @@ -153,7 +153,7 @@ namespace Sharpii { Console.WriteLine("ERROR: Unknown format type: {0}", tplFormat); Console.WriteLine("Error: SHARPII_NET_CORE_TPL_UNKNOWN_FORMAT_01"); - Environment.Exit(0x00000652); + Environment.Exit(0x00003E92); return; } @@ -211,7 +211,7 @@ namespace Sharpii Console.WriteLine(""); Console.WriteLine("ERROR DETAILS: {0}", ex.Message); Console.WriteLine("Error: SHARPII_NET_CORE_TPL_UNKNOWN_01"); - Environment.Exit(0x00000642); + Environment.Exit(0x00003E82); return; } } diff --git a/Sharpii/U8.cs b/Sharpii/U8.cs index 8c362e4..598f1e6 100644 --- a/Sharpii/U8.cs +++ b/Sharpii/U8.cs @@ -48,7 +48,7 @@ namespace Sharpii //If tuser gets here, they entered something wrong Console.WriteLine("ERROR: The argument {0} is invalid", args[1]); Console.WriteLine("Error: SHARPII_NET_CORE_U8_INVALID_ARG_01"); - Environment.Exit(0x00000650); + Environment.Exit(0x00003E90); return; } @@ -71,7 +71,7 @@ namespace Sharpii { Console.WriteLine("ERROR: File {0} is not a U8 archive", input); Console.WriteLine("Error: SHARPII_NET_CORE_U8_NON_U8_01"); - Environment.Exit(0x00000653); + Environment.Exit(0x00003E93); return; } @@ -106,7 +106,7 @@ namespace Sharpii Console.WriteLine(""); Console.WriteLine("ERROR DETAILS: {0}", ex.Message); Console.WriteLine("Error: SHARPII_NET_CORE_U8_UNKNOWN_01"); - Environment.Exit(0x00000642); + Environment.Exit(0x00003E82); return; } } @@ -126,7 +126,7 @@ namespace Sharpii Console.WriteLine("ERROR: Unable to open Folder: {0}", input); Console.WriteLine("Either the folder doesn't exist, or Sharpii doesn't have permission to open it."); Console.WriteLine("Error: SHARPII_NET_CORE_U8_FOLDER_ERR_01"); - Environment.Exit(0x00000654); + Environment.Exit(0x00003E94); return; } @@ -145,7 +145,7 @@ namespace Sharpii { Console.WriteLine("ERROR: No title set"); Console.WriteLine("Error: SHARPII_NET_CORE_U8_NO_TITLE_01"); - Environment.Exit(0x00000655); + Environment.Exit(0x00003E95); return; } imet = args[i + 1]; @@ -157,7 +157,7 @@ namespace Sharpii { Console.WriteLine("ERROR: Cannot use IMET and IMD5 at the same time."); Console.WriteLine("Error: SHARPII_NET_CORE_U8_TWO_HEADERS_01"); - Environment.Exit(0x00000656); + Environment.Exit(0x00003E96); return; } @@ -210,7 +210,7 @@ namespace Sharpii Console.WriteLine(""); Console.WriteLine("ERROR DETAILS: {0}", ex.Message); Console.WriteLine("Error: SHARPII_NET_CORE_U8_UNKNOWN_01"); - Environment.Exit(0x00000642); + Environment.Exit(0x00003E82); return; } } diff --git a/Sharpii/WAD.cs b/Sharpii/WAD.cs index 4ef1b5f..38104f8 100644 --- a/Sharpii/WAD.cs +++ b/Sharpii/WAD.cs @@ -80,7 +80,7 @@ namespace Sharpii //If tuser gets here, they entered something wrong Console.WriteLine("ERROR: The argument {0} is invalid", args[1]); Console.WriteLine("Error: SHARPII_NET_CORE_WAD_INVALID_ARG_01"); - Environment.Exit(0x00000650); + Environment.Exit(0x00003E90); return; } @@ -97,7 +97,7 @@ namespace Sharpii Console.WriteLine("ERROR: Unable to open file: {0}", input); Console.WriteLine("Either the file doesn't exist, or Sharpii doesn't have permission to open it."); Console.WriteLine("Error: SHARPII_NET_CORE_WAD_FILE_ERR_01"); - Environment.Exit(0x00000641); + Environment.Exit(0x00003E81); return; } @@ -110,7 +110,7 @@ namespace Sharpii { Console.WriteLine("ERROR: No output set"); Console.WriteLine("Error: SHARPII_NET_CORE_WAD_NO_OUTPUT_01"); - Environment.Exit(0x0000064D); + Environment.Exit(0x00003E8D); return; } output = args[i + 1]; @@ -120,7 +120,7 @@ namespace Sharpii { Console.WriteLine("ERROR: No output set"); Console.WriteLine("Error: SHARPII_NET_CORE_WAD_NO_OUTPUT_01"); - Environment.Exit(0x0000064D); + Environment.Exit(0x00003E8D); return; } output = args[i + 1]; @@ -214,7 +214,7 @@ namespace Sharpii Console.WriteLine(""); Console.WriteLine("ERROR DETAILS: {0}", ex.Message); Console.WriteLine("Error: SHARPII_NET_CORE_WAD_UNKNOWN_01"); - Environment.Exit(0x00000642); + Environment.Exit(0x00003E82); return; } } @@ -241,7 +241,7 @@ namespace Sharpii Console.WriteLine("ERROR: Unable to open file: {0}", input); Console.WriteLine("Either the file doesn't exist, or Sharpii doesn't have permission to open it."); Console.WriteLine("Error: SHARPII_NET_CORE_WAD_FILE_ERR_01"); - Environment.Exit(0x00000641); + Environment.Exit(0x00003E81); return; } if (edit == false) @@ -250,7 +250,7 @@ namespace Sharpii Console.WriteLine("ERROR: Unable to open folder: {0}", input); Console.WriteLine("Either the folder doesn't exist, or Sharpii doesn't have permission to open it."); Console.WriteLine("Error: SHARPII_NET_CORE_WAD_FOLDER_ERR_01"); - Environment.Exit(0x00000654); + Environment.Exit(0x00003E94); return; } @@ -266,7 +266,7 @@ namespace Sharpii { Console.WriteLine("ERROR: No ID set"); Console.WriteLine("Error: SHARPII_NET_CORE_WAD_NO_ID_01"); - Environment.Exit(0x0000064E); + Environment.Exit(0x00003E8E); return; } id = args[i + 1]; @@ -274,7 +274,7 @@ namespace Sharpii { Console.WriteLine("ERROR: ID too short"); Console.WriteLine("Error: SHARPII_NET_CORE_WAD_SHORT_ID_01"); - Environment.Exit(0x00000657); + Environment.Exit(0x00003E97); return; } id = id.Substring(0, 4); @@ -284,7 +284,7 @@ namespace Sharpii { Console.WriteLine("ERROR: No type set"); Console.WriteLine("Error: SHARPII_NET_CORE_WAD_NO_TYPE_01"); - Environment.Exit(0x00000658); + Environment.Exit(0x00003E98); return; } lwrid = args[i + 1].ToUpper(); @@ -292,7 +292,7 @@ namespace Sharpii { Console.WriteLine("ERROR: Unknown WAD type: {0}", args[i + 1]); Console.WriteLine("Error: SHARPII_NET_CORE_WAD_UNKNOWN_TYPE_01"); - Environment.Exit(0x00000659); + Environment.Exit(0x00003E99); return; } break; @@ -301,21 +301,21 @@ namespace Sharpii { Console.WriteLine("ERROR: No type set"); Console.WriteLine("Error: SHARPII_NET_CORE_WAD_NO_TYPE_01"); - Environment.Exit(0x00000658); + Environment.Exit(0x00003E98); return; } if (!int.TryParse(args[i + 1], out ios)) { Console.WriteLine("Invalid slot {0}...", args[i + 1]); Console.WriteLine("Error: SHARPII_NET_CORE_WAD_INVALID_SLOT_01"); - Environment.Exit(0x0000064A); + Environment.Exit(0x00003E8A); return; } if (ios < 0 || ios > 255) { Console.WriteLine("Invalid slot {0}...", ios); Console.WriteLine("Error: SHARPII_NET_CORE_WAD_INVALID_SLOT_01"); - Environment.Exit(0x0000064A); + Environment.Exit(0x00003E8A); return; } break; @@ -324,7 +324,7 @@ namespace Sharpii { Console.WriteLine("ERROR: No title set"); Console.WriteLine("Error: SHARPII_NET_CORE_WAD_NO_TITLE_01"); - Environment.Exit(0x00000655); + Environment.Exit(0x00003E95); return; } title = args[i + 1]; @@ -334,7 +334,7 @@ namespace Sharpii { Console.WriteLine("ERROR: No sound set"); Console.WriteLine("Error: SHARPII_NET_CORE_WAD_NO_SOUND_01"); - Environment.Exit(0x0000065A); + Environment.Exit(0x00003E9A); return; } sound = args[i + 1]; @@ -343,7 +343,7 @@ namespace Sharpii Console.WriteLine("ERROR: Unable to find sound wad"); Console.WriteLine("Either the file doesn't exist, or Sharpii doesn't have permission to open it."); Console.WriteLine("Error: SHARPII_NET_CORE_WAD_FILE_ERR_01"); - Environment.Exit(0x00000641); + Environment.Exit(0x00003E81); return; } break; @@ -352,7 +352,7 @@ namespace Sharpii { Console.WriteLine("ERROR: No banner set"); Console.WriteLine("Error: SHARPII_NET_CORE_WAD_NO_BANNER_01"); - Environment.Exit(0x0000065B); + Environment.Exit(0x00003E9B); return; } banner = args[i + 1]; @@ -361,7 +361,7 @@ namespace Sharpii Console.WriteLine("ERROR: Unable to find banner wad"); Console.WriteLine("Either the file doesn't exist, or Sharpii doesn't have permission to open it."); Console.WriteLine("Error: SHARPII_NET_CORE_WAD_FILE_ERR_01"); - Environment.Exit(0x00000641); + Environment.Exit(0x00003E81); return; } break; @@ -370,7 +370,7 @@ namespace Sharpii { Console.WriteLine("ERROR: No sound set"); Console.WriteLine("Error: SHARPII_NET_CORE_WAD_NO_SOUND_01"); - Environment.Exit(0x0000065A); + Environment.Exit(0x00003E9A); return; } icon = args[i + 1]; @@ -379,7 +379,7 @@ namespace Sharpii Console.WriteLine("ERROR: Unable to find icon wad"); Console.WriteLine("Either the file doesn't exist, or Sharpii doesn't have permission to open it."); Console.WriteLine("Error: SHARPII_NET_CORE_WAD_FILE_ERR_01"); - Environment.Exit(0x00000641); + Environment.Exit(0x00003E81); return; } break; @@ -388,7 +388,7 @@ namespace Sharpii { Console.WriteLine("ERROR: No dol set"); Console.WriteLine("Error: SHARPII_NET_CORE_WAD_NO_DOL_01"); - Environment.Exit(0x00000644); + Environment.Exit(0x00003E84); return; } app = args[i + 1]; @@ -397,7 +397,7 @@ namespace Sharpii Console.WriteLine("ERROR: Unable to find dol wad/file"); Console.WriteLine("Either the file doesn't exist, or Sharpii doesn't have permission to open it."); Console.WriteLine("Error: SHARPII_NET_CORE_WAD_FILE_ERR_01"); - Environment.Exit(0x00000641); + Environment.Exit(0x00003E81); return; } break; @@ -590,7 +590,7 @@ namespace Sharpii Console.WriteLine(""); Console.WriteLine("ERROR DETAILS: {0}", ex.Message); Console.WriteLine("Error: SHARPII_NET_CORE_WAD_UNKNOWN_01"); - Environment.Exit(0x00000642); + Environment.Exit(0x00003E82); return; } } @@ -608,7 +608,7 @@ namespace Sharpii Console.WriteLine("ERROR: Unable to open file: {0}", input); Console.WriteLine("Either the file doesn't exist, or Sharpii doesn't have permission to open it."); Console.WriteLine("Error: SHARPII_NET_CORE_WAD_FILE_ERR_01"); - Environment.Exit(0x00000641); + Environment.Exit(0x00003E81); return; } @@ -653,7 +653,7 @@ namespace Sharpii Console.WriteLine(""); Console.WriteLine("ERROR DETAILS: {0}", ex.Message); Console.WriteLine("Error: SHARPII_NET_CORE_WAD_UNKNOWN_01"); - Environment.Exit(0x00000642); + Environment.Exit(0x00003E82); return; } }