From 7b64f06d798a236d5d08c6cf517de661285ba88f Mon Sep 17 00:00:00 2001 From: LordGrimmauld Date: Wed, 17 Jun 2020 08:13:28 +0200 Subject: [PATCH] fix tank flow priorities --- .../content/contraptions/fluids/FluidTankTileEntity.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/java/com/simibubi/create/content/contraptions/fluids/FluidTankTileEntity.java b/src/main/java/com/simibubi/create/content/contraptions/fluids/FluidTankTileEntity.java index 2e2c70d1a..1ffc9692e 100644 --- a/src/main/java/com/simibubi/create/content/contraptions/fluids/FluidTankTileEntity.java +++ b/src/main/java/com/simibubi/create/content/contraptions/fluids/FluidTankTileEntity.java @@ -27,7 +27,7 @@ public class FluidTankTileEntity extends SmartTileEntity { } private int calculateDrainAmount(FluidTankTileEntity other, int delta) { - boolean roundDirection = other.getPriority() > this.getPriority(); + boolean roundDirection = other.getPriority() < this.getPriority(); return (int) Math.abs(roundDirection ? Math.floor(delta / 2f) : Math.ceil(delta / 2f)); } @@ -134,7 +134,7 @@ public class FluidTankTileEntity extends SmartTileEntity { private void updatePriority() { FluidTankTileEntity other = getOtherFluidTankTileEntity(Direction.DOWN); priority = 1000; - if (other != null && other.getTank().getFluidAmount() < other.getTank().getCapacity()) { + if (other != null) { priority = 0; return; }