@Override
public void write(ChannelHandlerContext ctx, Object msg, ChannelPromise promise) throws Exception
{
if (msg instanceof FMLProxyPacket)
{
if (side == Side.CLIENT)
{
//Client to server large packets are not supported to prevent client being bad.
ctx.write(((FMLProxyPacket) msg).toC17Packet(), promise);
}
else
{
List<Packet<INetHandlerPlayClient>> parts = ((FMLProxyPacket)msg).toS3FPackets();
for (Packet<INetHandlerPlayClient> pkt : parts)
{
ctx.write(pkt, promise);
}
}
}
else
{
ctx.write(msg, promise);
}
}
NetworkDispatcher.java 文件源码
java
阅读 23
收藏 0
点赞 0
评论 0
项目:CustomWorldGen
作者:
评论列表
文章目录