mirror of
https://github.com/MCCTeam/Minecraft-Console-Client
synced 2025-11-07 17:36:07 +00:00
parent
bd3f75cfc5
commit
bdbd8ab0b8
2 changed files with 2 additions and 5 deletions
|
|
@ -42,14 +42,12 @@ namespace MinecraftClient
|
||||||
private McTcpClient _handler = null;
|
private McTcpClient _handler = null;
|
||||||
private ChatBot master = null;
|
private ChatBot master = null;
|
||||||
private Queue<string> chatQueue = new Queue<string>();
|
private Queue<string> chatQueue = new Queue<string>();
|
||||||
private DateTime? lastMessageSentTime = null;
|
private DateTime? lastMessageSentTime = DateTime.MinValue;
|
||||||
private bool CanSendTextNow
|
private bool CanSendTextNow
|
||||||
{
|
{
|
||||||
get
|
get
|
||||||
{
|
{
|
||||||
return lastMessageSentTime != null
|
return DateTime.Now > lastMessageSentTime.Value + Settings.botMessageDelay;
|
||||||
? DateTime.Now > lastMessageSentTime.Value + Settings.botMessageDelay
|
|
||||||
: true;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -90,7 +90,6 @@ namespace MinecraftClient.Protocol.Handlers
|
||||||
tmp = tmp[1].Split(new string[] { "hash\": \"" }, StringSplitOptions.None);
|
tmp = tmp[1].Split(new string[] { "hash\": \"" }, StringSplitOptions.None);
|
||||||
string hash = tmp[1].Split('"')[0]; //Translations file identifier on Mojang's servers
|
string hash = tmp[1].Split('"')[0]; //Translations file identifier on Mojang's servers
|
||||||
System.IO.File.WriteAllText(Language_File, downloadString(Settings.TranslationsFile_Website_Download + '/' + hash.Substring(0, 2) + '/' + hash));
|
System.IO.File.WriteAllText(Language_File, downloadString(Settings.TranslationsFile_Website_Download + '/' + hash.Substring(0, 2) + '/' + hash));
|
||||||
Console.WriteLine(hash);
|
|
||||||
ConsoleIO.WriteLine("Done. File saved as '" + Language_File + '\'');
|
ConsoleIO.WriteLine("Done. File saved as '" + Language_File + '\'');
|
||||||
}
|
}
|
||||||
catch
|
catch
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue