implimented isStackValidForSlot to return true if valid to allow for automation inserst (mainly Applied Energistics)

Signed-off-by: Andrew Meehan <andrew@meehan.me.uk>
This commit is contained in:
Andrew Meehan 2013-05-08 10:18:29 -04:00
parent 655a31ecd4
commit d559946562
2 changed files with 19 additions and 1 deletions

View file

@ -106,4 +106,22 @@ public class TileHopper extends TileBuildCraft implements IInventory {
@Override
public void closeChest() {
}
@Override
public boolean isStackValidForSlot(int i, ItemStack itemstack)
{
TileEntity tile = this.worldObj.getBlockTileEntity(xCoord, yCoord - 1, zCoord);
if(tile == null)
{
return false;
}
if(tile instanceof IInventory)
{
return ((IInventory)tile).isStackValidForSlot(i, itemstack);
}
return false;
}
}

View file

@ -504,6 +504,6 @@ public class TileAssemblyTable extends TileEntity implements IMachine, IInventor
public boolean isStackValidForSlot(int i, ItemStack itemstack)
{
// TODO Auto-generated method stub
return false;
return true;
}
}