From f227dc2afcd4f15741566213ee6f02083137ef99 Mon Sep 17 00:00:00 2001 From: SpaceToad Date: Mon, 10 Feb 2014 16:05:05 +0100 Subject: [PATCH] fixed items traveling in pipes --- common/buildcraft/BuildCraftMod.java | 6 +++++- .../network/BuildCraftChannelHandler.java | 20 +++++++++++++++++++ .../transport/PipeTransportItems.java | 5 ++++- .../PacketPipeTransportItemStackRequest.java | 6 +++++- 4 files changed, 34 insertions(+), 3 deletions(-) diff --git a/common/buildcraft/BuildCraftMod.java b/common/buildcraft/BuildCraftMod.java index a85162da..73874e92 100755 --- a/common/buildcraft/BuildCraftMod.java +++ b/common/buildcraft/BuildCraftMod.java @@ -30,10 +30,14 @@ public class BuildCraftMod { channels.get(Side.SERVER).attr(FMLOutboundHandler.FML_MESSAGETARGETARGS).set(entityplayer); channels.get(Side.SERVER).writeOutbound(packet); } + + public void replyToPlayer(EntityPlayer entityplayer, BuildCraftPacket packet) { + channels.get(Side.SERVER).attr(FMLOutboundHandler.FML_MESSAGETARGET).set(OutboundTarget.REPLY); + channels.get(Side.SERVER).writeOutbound(packet); + } public void sendToServer(BuildCraftPacket packet) { channels.get(Side.CLIENT).attr(FMLOutboundHandler.FML_MESSAGETARGET).set(OutboundTarget.TOSERVER); channels.get(Side.CLIENT).writeOutbound(packet); } - } \ No newline at end of file diff --git a/common/buildcraft/core/network/BuildCraftChannelHandler.java b/common/buildcraft/core/network/BuildCraftChannelHandler.java index f9a83e60..d1a7711a 100755 --- a/common/buildcraft/core/network/BuildCraftChannelHandler.java +++ b/common/buildcraft/core/network/BuildCraftChannelHandler.java @@ -1,5 +1,12 @@ package buildcraft.core.network; +import buildcraft.builders.network.PacketLibraryAction; +import buildcraft.transport.network.PacketFluidUpdate; +import buildcraft.transport.network.PacketGateExpansionMap; +import buildcraft.transport.network.PacketPipeTransportItemStack; +import buildcraft.transport.network.PacketPipeTransportItemStackRequest; +import buildcraft.transport.network.PacketPipeTransportTraveler; +import buildcraft.transport.network.PacketPowerUpdate; import cpw.mods.fml.common.network.FMLIndexedMessageToMessageCodec; import io.netty.buffer.ByteBuf; import io.netty.channel.ChannelHandlerContext; @@ -9,6 +16,19 @@ public class BuildCraftChannelHandler extends FMLIndexedMessageToMessageCodec