public function sendPacket(Packet $packet)
    {
        // Create a raw packet
        $rawPacket = $packet->convertToRcon();

        // Attach size
        $rawPacket = pack('V', mb_strlen($rawPacket)).$rawPacket;

        // Write to the socket
        $this->socket->write($rawPacket);

        // Read the packet size
        $packetSize = $this->socket->read(4);
        $packetSize = unpack('V', $packetSize);
        $packetSize = reset($packetSize);

        // TODO: multi-packet responses

        // Read the packet
        $rawPacket = $this->socket->read($packetSize);

        // Parse and return the packet
        return Packet::createFromRcon($rawPacket);
    }