public void SendPayload(ArraySegment <byte> buffer) { // TODO: Remove this copy byte[] toSend = new byte[buffer.Count + 1]; toSend[0] = PacketWriter.EncodePacketType(EPacket.Persistence); Array.Copy(buffer.Array, buffer.Offset, toSend, 1, buffer.Count); m_Connection.SendRaw(new ArraySegment <byte>(toSend), EDeliveryMethod.Reliable); }