createRequest method

  1. @override
Buffer createRequest()
override

Returns a Buffer containing the command packet.

Implementation

@override
Buffer createRequest() {
  var buffer = Buffer(32);
  buffer.seekWrite(0);
  buffer.writeUint32(clientFlags);
  buffer.writeUint32(maxPacketSize);
  buffer.writeByte(characterSet);
  buffer.fill(23, 0);

  return buffer;
}