This commit is contained in:
modmuss50 2019-08-26 20:11:55 +01:00
parent aa5d81dbe8
commit a19c25a504

View file

@ -88,7 +88,7 @@ public abstract class BaseFluidGeneratorBlockEntity extends PowerAcceptorBlockEn
if (FluidUtils.isContainerEmpty(inputStack) && tank.getFluidAmount() > 0) { if (FluidUtils.isContainerEmpty(inputStack) && tank.getFluidAmount() > 0) {
FluidUtils.fillContainers(tank, inventory, 0, 1, tank.getFluid()); FluidUtils.fillContainers(tank, inventory, 0, 1, tank.getFluid());
} }
else if (getRecipes().getRecipeForFluid(((ItemFluidInfo) inputStack.getItem()).getFluid(inputStack)).isPresent()) { else if (inputStack.getItem() instanceof ItemFluidInfo && getRecipes().getRecipeForFluid(((ItemFluidInfo) inputStack.getItem()).getFluid(inputStack)).isPresent()) {
FluidUtils.drainContainers(tank, inventory, 0, 1); FluidUtils.drainContainers(tank, inventory, 0, 1);
} }
} }