Add basic ME Conduits.

Non-rendering, function as basic 8-channel conduits
This commit is contained in:
tterrag1098 committed 2014-10-31 22:36:31 -04:00
1 parent 63e1a1dc1d
commit c764cfdd0d
33 files changed
+396 -61

No files matched your search

@@ -159,7 +159,7 @@ public class LiquidConduitNetwork extends AbstractTankConduitNetwork<LiquidCondu
if(con.canOutputToDir(dir)) {
IFluidHandler externalTank = con.getExternalHandler(dir);
if(externalTank != null) {
externals.add(new LocatedFluidHandler(externalTank, con.getLocation().getLocation(dir), dir.getOpposite()));
externals.add(new LocatedFluidHandler(externalTank, con.getBlockCoord().getLocation(dir), dir.getOpposite()));
}
}
}
@@ -193,7 +193,7 @@ public class LiquidConduitNetwork extends AbstractTankConduitNetwork<LiquidCondu
}
private void drainConduitToNearestExternal(LiquidConduit con, List<LocatedFluidHandler> externals) {
BlockCoord conLoc = con.getLocation();
BlockCoord conLoc = con.getBlockCoord();
FluidStack toDrain = con.getTank().getFluid();
if(toDrain == null) {
return;
@@ -230,7 +230,7 @@ public class LiquidConduitNetwork extends AbstractTankConduitNetwork<LiquidCondu
// First flow all we can down, then balance the rest
if(con.getConduitConnections().contains(ForgeDirection.DOWN)) {
BlockCoord loc = con.getLocation().getLocation(ForgeDirection.DOWN);
BlockCoord loc = con.getBlockCoord().getLocation(ForgeDirection.DOWN);
ILiquidConduit dc = ConduitUtil.getConduit(con.getBundle().getEntity().getWorldObj(), loc.x, loc.y, loc.z, ILiquidConduit.class);
if(dc instanceof LiquidConduit) {
LiquidConduit downCon = (LiquidConduit) dc;
@@ -290,7 +290,7 @@ public class LiquidConduitNetwork extends AbstractTankConduitNetwork<LiquidCondu
}
int totalCapacity = tank.getCapacity();
BlockCoord loc = con.getLocation();
BlockCoord loc = con.getBlockCoord();
Collection<ILiquidConduit> connections =
ConduitUtil.getConnectedConduits(con.getBundle().getEntity().getWorldObj(),
loc.x, loc.y, loc.z, ILiquidConduit.class);
@@ -331,7 +331,7 @@ public class LiquidConduitNetwork extends AbstractTankConduitNetwork<LiquidCondu
if(neighbour.getNetwork() != this) {
return false;
}
if(neighbour.getLocation().y > con.getLocation().y) {
if(neighbour.getBlockCoord().y > con.getBlockCoord().y) {
return false;
}
float nr = neighbour.getTank().getFilledRatio();