mirror of
https://github.com/GTNewHorizons/EnderIO.git
synced 2026-11-27 15:33:06 +00:00
Unify code to fill/empty buckets, Part 2
* New: Emptying buckets * Fix: Fixed many bugs, including some item-loss types * Full IN+OUT: Tank, Reservoir, XP Obelisk, Soul Binder * IN for input liquid, OUT for output liquid: Vat * IN for fuel, OUT fro XP: KillerJoe * IN for fuel: Zombie Generator * IN for fuel/coolant: Combustion Generator
This commit is contained in:
1 parent
d99aa045ba
commit
f2f6bdd325
22 files changed
+541
-408
No files matched your search
@@ -21,6 +21,8 @@ import cpw.mods.fml.relauncher.SideOnly;
|
||||
import crazypants.enderio.api.tool.ITool;
|
||||
import crazypants.enderio.machine.AbstractMachineEntity;
|
||||
import crazypants.enderio.tool.ToolUtil;
|
||||
import crazypants.util.FluidUtil;
|
||||
import crazypants.util.ITankAccess;
|
||||
|
||||
public abstract class BlockEio extends Block {
|
||||
|
||||
@@ -91,6 +93,14 @@ public abstract class BlockEio extends Block {
|
||||
world.markBlockForUpdate(x, y, z);
|
||||
return true;
|
||||
}
|
||||
if (te instanceof ITankAccess) {
|
||||
if (FluidUtil.fillInternalTankFromPlayerHandItem(world, x, y, z, entityPlayer, (ITankAccess) te)) {
|
||||
return true;
|
||||
}
|
||||
if (FluidUtil.fillPlayerHandItemFromInternalTank(world, x, y, z, entityPlayer, (ITankAccess) te)) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if(entityPlayer.isSneaking()) {
|
||||
|
||||
Reference in new issue
Block a user