diff --git a/MinecraftClient/ChatParser.cs b/MinecraftClient/ChatParser.cs index 203d6bc7..bf5fe6cd 100644 --- a/MinecraftClient/ChatParser.cs +++ b/MinecraftClient/ChatParser.cs @@ -118,9 +118,8 @@ namespace MinecraftClient else //No external dictionnary found. { Console.ForegroundColor = ConsoleColor.DarkGray; - ConsoleIO.WriteLine("MC 1.6+ warning: Translations file \"" + Settings.TranslationsFile + "\" not found." + ConsoleIO.WriteLine("MC 1.6+ warning: Translations file not found: \"" + Settings.TranslationsFile + "\"" + "\nYou can pick a translation file from .minecraft\\assets\\lang\\" - + "\nCopy to the same folder as MinecraftClient & rename to \"" + Settings.TranslationsFile + "\"" + "\nSome messages won't be properly printed without this file."); Console.ForegroundColor = ConsoleColor.Gray; } diff --git a/MinecraftClient/Crypto.cs b/MinecraftClient/Crypto.cs index 91b78953..d30d6cf1 100644 --- a/MinecraftClient/Crypto.cs +++ b/MinecraftClient/Crypto.cs @@ -7,8 +7,6 @@ using java.security; using java.security.spec; using javax.crypto; using javax.crypto.spec; -using Org.BouncyCastle.Crypto; -using Org.BouncyCastle.Crypto.Parameters; namespace MinecraftClient { @@ -27,9 +25,9 @@ namespace MinecraftClient public static SecretKey GenerateAESPrivateKey() { - CipherKeyGenerator var0 = new CipherKeyGenerator(); - var0.Init(new KeyGenerationParameters(new Org.BouncyCastle.Security.SecureRandom(), 128)); - return new SecretKeySpec(var0.GenerateKey(), "AES"); + AesManaged aes = new AesManaged(); + aes.KeySize = 128; aes.GenerateKey(); + return new SecretKeySpec(aes.Key, "AES"); } public static byte[] getServerHash(String toencode, PublicKey par1PublicKey, SecretKey par2SecretKey) diff --git a/MinecraftClient/MinecraftClient.csproj b/MinecraftClient/MinecraftClient.csproj index a2d8ad1f..aba910f0 100644 --- a/MinecraftClient/MinecraftClient.csproj +++ b/MinecraftClient/MinecraftClient.csproj @@ -119,7 +119,6 @@ - diff --git a/MinecraftClient/MinecraftClient.csproj.user b/MinecraftClient/MinecraftClient.csproj.user index f2fdfed5..c0a75d71 100644 --- a/MinecraftClient/MinecraftClient.csproj.user +++ b/MinecraftClient/MinecraftClient.csproj.user @@ -14,7 +14,6 @@ false - - + TestBot - localhost \ No newline at end of file diff --git a/MinecraftClient/Settings.cs b/MinecraftClient/Settings.cs index 371ed568..e3d3fded 100644 --- a/MinecraftClient/Settings.cs +++ b/MinecraftClient/Settings.cs @@ -33,8 +33,8 @@ namespace MinecraftClient //Hangman Settings public static bool Hangman_Enabled = false; public static bool Hangman_English = true; - public static string Hangman_FileWords_EN = "words.txt"; - public static string Hangman_FileWords_FR = "mots.txt"; + public static string Hangman_FileWords_EN = "hangman-en.txt"; + public static string Hangman_FileWords_FR = "hangman-fr.txt"; //Alerts Settings public static bool Alerts_Enabled = false; @@ -193,7 +193,7 @@ namespace MinecraftClient public static void WriteDefaultSettings(string settingsfile) { - System.IO.File.WriteAllText(settingsfile, "#Minecraft Console Client v" + Program.Version + "\r\n#Startup Config File\r\n\r\n[Main]\r\n\r\n#General settings\r\n#leave blank = prompt user on startup\r\n#Use \"-\" as password for offline mode\r\n\r\nlogin=\r\npassword=\r\nserverip=\r\n\r\n#Advanced settings\r\n\r\ntranslationsfile=translations.lang\r\nbotownersfile=bot-owners.txt\r\nconsoletitle=Minecraft Console Client\r\n\r\n#Bot Settings\r\n\r\n[Alerts]\r\nenabled=false\r\nalertsfile=alerts.txt\r\nexcludesfile=alerts-exclude.txt\r\n\r\n[AntiAFK]\r\nenabled=false\r\ndelay=600 #10 = 1s\r\n\r\n[AutoRelog]\r\nenabled=false\r\ndelay=10\r\nretries=3\r\nkickmessagesfile=kickmessages.txt\r\n\r\n[ChatLog]\r\nenabled=false\r\ntimestamps=true\r\nfilter=messages\r\nlogfile=chatlog.txt\r\n\r\n[Hangman]\r\nenabled=false\r\nenglish=true\r\nwordsfile=words.txt\r\nfichiermots=mots.txt\r\n\r\n[Scripting]\r\nenabled=false\r\nscriptfile=testscript.txt\r\n"); + System.IO.File.WriteAllText(settingsfile, "#Minecraft Console Client v" + Program.Version + "\r\n#Startup Config File\r\n\r\n[Main]\r\n\r\n#General settings\r\n#leave blank = prompt user on startup\r\n#Use \"-\" as password for offline mode\r\n\r\nlogin=\r\npassword=\r\nserverip=\r\n\r\n#Advanced settings\r\n\r\ntranslationsfile=translations.lang\r\nbotownersfile=bot-owners.txt\r\nconsoletitle=Minecraft Console Client\r\n\r\n#Bot Settings\r\n\r\n[Alerts]\r\nenabled=false\r\nalertsfile=alerts.txt\r\nexcludesfile=alerts-exclude.txt\r\n\r\n[AntiAFK]\r\nenabled=false\r\ndelay=600 #10 = 1s\r\n\r\n[AutoRelog]\r\nenabled=false\r\ndelay=10\r\nretries=3 #-1 = unlimited\r\nkickmessagesfile=kickmessages.txt\r\n\r\n[ChatLog]\r\nenabled=false\r\ntimestamps=true\r\nfilter=messages\r\nlogfile=chatlog.txt\r\n\r\n[Hangman]\r\nenabled=false\r\nenglish=true\r\nwordsfile=hangman-en.txt\r\nfichiermots=hangman-fr.txt\r\n\r\n[Scripting]\r\nenabled=false\r\nscriptfile=testscript.txt\r\n", Encoding.UTF8); } public static int str2int(string str) { try { return Convert.ToInt32(str); } catch { return 0; } } diff --git a/MinecraftClient/lib/BouncyCastle.Crypto.dll b/MinecraftClient/lib/BouncyCastle.Crypto.dll deleted file mode 100644 index 8531f7fc..00000000 Binary files a/MinecraftClient/lib/BouncyCastle.Crypto.dll and /dev/null differ