mirror of
https://github.com/MinecraftForge/MinecraftForge.git
synced 2026-11-13 00:37:52 +00:00
This commit is contained in:
1 parent
704b683e27
commit
f20d728ed7
2 files changed
+9
-5
No files matched your search
@@ -72,8 +72,6 @@ public class DispenseFluidContainer extends BehaviorDefaultDispenseItem
|
||||
return super.dispenseStack(source, stack);
|
||||
}
|
||||
|
||||
world.setBlockToAir(blockpos);
|
||||
|
||||
if (--stack.stackSize == 0)
|
||||
{
|
||||
stack.deserializeNBT(result.serializeNBT());
|
||||
|
||||
@@ -495,10 +495,16 @@ public class FluidUtil
|
||||
return null;
|
||||
}
|
||||
|
||||
IFluidHandler targetFluidHandler = FluidUtil.getFluidHandler(worldIn, pos, side);
|
||||
if (targetFluidHandler != null)
|
||||
IBlockState state = worldIn.getBlockState(pos);
|
||||
Block block = state.getBlock();
|
||||
|
||||
if (block instanceof IFluidBlock || block instanceof BlockLiquid)
|
||||
{
|
||||
return FluidUtil.tryFillContainer(emptyContainer, targetFluidHandler, Integer.MAX_VALUE, playerIn, true);
|
||||
IFluidHandler targetFluidHandler = FluidUtil.getFluidHandler(worldIn, pos, side);
|
||||
if (targetFluidHandler != null)
|
||||
{
|
||||
return FluidUtil.tryFillContainer(emptyContainer, targetFluidHandler, Integer.MAX_VALUE, playerIn, true);
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user