/// <summary> /// Throws an exception with message format ns message<br/>buffer. /// </summary> public NetStateMsgException(INetState ns, string message, byte[] buffer, int length) : base($"{(ns?.ToString() ?? "unknown")} {message}{Environment.NewLine}{BufferFormat.AsString(buffer, length)}") { }
/// <summary> /// Throws an exception with message format ns message<br/>buffer. /// </summary> public NetStateMsgException(INetState ns, string message, PacketReader reader) : base($"{(ns?.ToString() ?? "unknown")} {message}{Environment.NewLine}{BufferFormat.AsString(reader.Buffer, reader.Length)}") { }