Set creative tank amount to capacity on tick. Fix #2558. Thanks to Technici4n

* Set creative tank amount to capacity on tick. Fix #2558.
* Remove FluidValue.INFINITE
* Was better with the /1000
This commit is contained in:
Technici4n 2021-10-08 07:49:19 +02:00 committed by GitHub
parent f39c619c22
commit 165d27cfda
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 1 additions and 2 deletions

View file

@ -37,7 +37,6 @@ public final class FluidValue {
public static final FluidValue EMPTY = new FluidValue(0);
public static final FluidValue BUCKET_QUARTER = new FluidValue(FluidConstants.BUCKET / 4);
public static final FluidValue BUCKET = new FluidValue(FluidConstants.BUCKET);
public static final FluidValue INFINITE = new FluidValue(Long.MAX_VALUE);
private final long rawValue;

View file

@ -100,7 +100,7 @@ public class TankUnitBaseBlockEntity extends MachineBaseBlockEntity implements I
if (type == TRContent.TankUnit.CREATIVE) {
if (!tank.isEmpty() && !tank.isFull()) {
tank.setFluidAmount(FluidValue.INFINITE);
tank.setFluidAmount(tank.getFluidValueCapacity());
}
}
syncWithAll();