right now vanilla uses writeAndFlush for sending packet in NetworkManager#dispatchPacket. This will s end a TCP packet for each individual packet for each tick, this causes alot of traffic for very little data amoutn because of the big TCP header. by only calling write and then flush each tick (or per two ticks) it would exrtremly reduce the traffic amount (from tousands of packet with ~8 bytes)
Edit: to also improve modded connections I think we should edit the FMLEmbeddedChannel and over write the writeAndFlush method to only call write and set a flag to flush from an extra trimer.
Also is FMLEmbeddedChannel everywere used or do we have different channles?
right now vanilla uses
writeAndFlushfor sending packet inNetworkManager#dispatchPacket. This will s end a TCP packet for each individual packet for each tick, this causes alot of traffic for very little data amoutn because of the big TCP header. by only calling write and then flush each tick (or per two ticks) it would exrtremly reduce the traffic amount (from tousands of packet with ~8 bytes)Edit: to also improve modded connections I think we should edit the
FMLEmbeddedChanneland over write thewriteAndFlushmethod to only call write and set a flag to flush from an extra trimer.Also is FMLEmbeddedChannel everywere used or do we have different channles?