mirror of
https://github.com/GTNewHorizons/EnderIO.git
synced 2026-11-26 15:03:07 +00:00
45 lines
1.3 KiB
Java
45 lines
1.3 KiB
Java
package crazypants.enderio.machine.tank;
|
|
|
|
import net.minecraft.entity.player.InventoryPlayer;
|
|
import net.minecraft.inventory.Slot;
|
|
import net.minecraft.item.ItemStack;
|
|
import crazypants.enderio.machine.AbstractMachineEntity;
|
|
import crazypants.enderio.machine.gui.AbstractMachineContainer;
|
|
|
|
public class ContainerTank extends AbstractMachineContainer {
|
|
|
|
public ContainerTank(InventoryPlayer playerInv, AbstractMachineEntity te) {
|
|
super(playerInv, te);
|
|
}
|
|
|
|
@Override
|
|
protected void addMachineSlots(InventoryPlayer playerInv) {
|
|
addSlotToContainer(new Slot(tileEntity, 0, 44, 21) {
|
|
@Override
|
|
public boolean isItemValid(ItemStack itemStack) {
|
|
return tileEntity.isItemValidForSlot(0, itemStack);
|
|
}
|
|
});
|
|
addSlotToContainer(new Slot(tileEntity, 1, 116, 21) {
|
|
@Override
|
|
public boolean isItemValid(ItemStack itemStack) {
|
|
return tileEntity.isItemValidForSlot(1, itemStack);
|
|
}
|
|
});
|
|
addSlotToContainer(new Slot(tileEntity, 2, 44, 52) {
|
|
@Override
|
|
public boolean isItemValid(ItemStack itemStack) {
|
|
return tileEntity.isItemValidForSlot(2, itemStack);
|
|
}
|
|
});
|
|
addSlotToContainer(new Slot(tileEntity, 3, 116, 52) {
|
|
@Override
|
|
public boolean isItemValid(ItemStack itemStack) {
|
|
return tileEntity.isItemValidForSlot(3, itemStack);
|
|
}
|
|
});
|
|
|
|
}
|
|
|
|
}
|