package org.cyclops.cyclopscore.inventory.slot;

import lombok.Getter;
import lombok.Setter;
import net.minecraft.inventory.IInventory;
import net.minecraft.inventory.Slot;
import net.minecraft.item.ItemStack;

/**
 * A slot with some fancy and fun extra features.
 * @author rubensworks
 */
public class SlotExtended extends Slot {

    @Getter
    @Setter
    private boolean enabled = true;

    @Getter
    @Setter
    private boolean phantom = false;

    @Getter
    @Setter
    private boolean adjustable = true;

    public SlotExtended(IInventory inventoryIn, int index, int x, int y) {
        super(inventoryIn, index, x, y);
    }

    @Override
    public boolean isItemValid(ItemStack stack) {
        return isEnabled() && inventory.isItemValidForSlot(getSlotIndex(), stack);
    }

}

@@ -82,24 +82,73 @@
 bok.Setter;%0A
+import net.minecraft.entity.player.EntityPlayer;%0A
 import net.m
@@ -840,10 +840,148 @@
 %0A    %7D%0A%0A
+    @Override%0A    public boolean canTakeStack(EntityPlayer playerIn) %7B%0A        return super.canTakeStack(playerIn) && !isPhantom();%0A    %7D%0A
 %7D%0A

Fix being able to take items out of phantom slots, Closes CyclopsMC/IntegratedDynamics#297