public override string ToString() { return(Version.ToString() + "\t" + SubVersion.ToString() + "\t" + (string.IsNullOrEmpty(Url) ? " " : Url) + "\t" + (string.IsNullOrEmpty(Error) ? " " : Error.Replace('\t', ' '))); }
public void SendHandshake() { if (Socket == null) { return; } var sIv = Functions.RandomUInt(); var rIv = Functions.RandomUInt(); Socket.Cipher.SetVectors(sIv, rIv); var writer = new PacketWriter(); writer.WriteUShort(0x0E); writer.WriteUShort(Version); writer.WriteString(SubVersion.ToString()); writer.WriteUInt(rIv); writer.WriteUInt(sIv); writer.WriteByte(ServerType); Socket.SendRawPacket(writer.ToArray()); }