public ByteBuf encode(ExplosionMessage message) throws IOException {
ByteBuf buffer = Unpooled.buffer();
buffer.writeDouble(message.getX());
buffer.writeDouble(message.getY());
buffer.writeDouble(message.getZ());
buffer.writeFloat(message.getRadius());
buffer.writeInt(message.getRecords());
buffer.writeBytes(message.getCoordinates());
buffer.writeFloat(0.0f); // unknown (x?)
buffer.writeFloat(0.0f); // unknown (y?)
buffer.writeFloat(0.0f); // unknown (z?)