Merge pull request #1 from dogwatch/patch-1

Merging changes.
This commit is contained in:
ORelio 2013-07-18 13:44:57 -07:00
commit 255a44a9cc

View file

@ -778,12 +778,12 @@ namespace MinecraftClient
byte[] chat = new byte[3 + (message.Length * 2)]; byte[] chat = new byte[3 + (message.Length * 2)];
chat[0] = (byte)3; chat[0] = (byte)3;
byte[] msglen = new byte[2]; byte[] msglen;
msglen = BitConverter.GetBytes((short)message.Length); msglen = BitConverter.GetBytes((short)message.Length);
Array.Reverse(msglen); Array.Reverse(msglen);
msglen.CopyTo(chat, 1); msglen.CopyTo(chat, 1);
byte[] msg = new byte[message.Length * 2]; byte[] msg;
msg = Encoding.Unicode.GetBytes(message); msg = Encoding.Unicode.GetBytes(message);
Array.Reverse(msg); Array.Reverse(msg);
msg.CopyTo(chat, 3); msg.CopyTo(chat, 3);
@ -801,12 +801,12 @@ namespace MinecraftClient
byte[] reason = new byte[3 + (message.Length * 2)]; byte[] reason = new byte[3 + (message.Length * 2)];
reason[0] = (byte)0xff; reason[0] = (byte)0xff;
byte[] msglen = new byte[2]; byte[] msglen;
msglen = BitConverter.GetBytes((short)message.Length); msglen = BitConverter.GetBytes((short)message.Length);
Array.Reverse(msglen); Array.Reverse(msglen);
msglen.CopyTo(reason, 1); msglen.CopyTo(reason, 1);
byte[] msg = new byte[message.Length * 2]; byte[] msg;
msg = Encoding.Unicode.GetBytes(message); msg = Encoding.Unicode.GetBytes(message);
Array.Reverse(msg); Array.Reverse(msg);
msg.CopyTo(reason, 3); msg.CopyTo(reason, 3);