Add delay to bin eject, removed old transmitters from creative tab, fixed descriptions of transmitters

This commit is contained in:
Aidan Brady 2013-12-22 00:53:27 -05:00
parent 4812b432fd
commit 3210153f38
3 changed files with 44 additions and 21 deletions

View file

@ -63,7 +63,6 @@ public class BlockTransmitter extends Block
super(id, Material.wood);
setHardness(2.0F);
setResistance(5.0F);
setCreativeTab(Mekanism.tabMekanism);
}
public float getMinBound(IBlockAccess world, int x, int y, int z)

View file

@ -95,25 +95,41 @@ public class ItemPartTransmitter extends JItemMultiPart
list.add("- " + EnumColor.PURPLE + "EU " + EnumColor.GREY + "(IndustrialCraft)");
list.add("- " + EnumColor.PURPLE + "MJ " + EnumColor.GREY + "(BuildCraft)");
list.add("- " + EnumColor.PURPLE + "Joules " + EnumColor.GREY + "(Mekanism)");
break;
}
case 1:
{
list.add(EnumColor.DARK_GREY + "Capable of transferring:");
list.add("- " + EnumColor.PURPLE + "mB " + EnumColor.GREY + "(FluidRegistry)");
break;
}
case 2:
{
list.add(EnumColor.DARK_GREY + "Capable of transferring:");
list.add("- " + EnumColor.PURPLE + "O " + EnumColor.GREY + "(Oxygen)");
list.add("- " + EnumColor.PURPLE + "H " + EnumColor.GREY + "(Hydrogen)");
break;
}
case 3:
{
list.add(EnumColor.DARK_GREY + "Capable of transferring:");
list.add("- " + EnumColor.PURPLE + "Items (universal)");
list.add("- " + EnumColor.PURPLE + "Blocks (universal)");
}
case 4:
{
list.add(EnumColor.DARK_GREY + "Capable of transferring:");
list.add("- " + EnumColor.PURPLE + "Items (universal)");
list.add("- " + EnumColor.PURPLE + "Blocks (universal)");
list.add("- " + EnumColor.DARK_RED + "Only used if no other paths available");
}
case 5:
{
list.add(EnumColor.DARK_GREY + "Capable of transferring:");
list.add("- " + EnumColor.PURPLE + "Items (universal)");
list.add("- " + EnumColor.PURPLE + "Blocks (universal)");
list.add("- " + EnumColor.DARK_RED + "Controllable by redstone");
}
}
if(itemstack.getItemDamage() >= 3 && itemstack.getItemDamage() <= 5)
{
list.add(EnumColor.DARK_GREY + "Capable of transferring:");
list.add("- " + EnumColor.PURPLE + "Items (universal)");
list.add("- " + EnumColor.PURPLE + "Blocks (universal)");
}
}
}

View file

@ -188,25 +188,33 @@ public class TileEntityBin extends TileEntityBasicBlock implements ISidedInvento
MekanismUtils.saveChunk(this);
}
if(bottomStack != null && isActive && delayTicks == 0)
if(delayTicks == 0)
{
TileEntity tile = Coord4D.get(this).getFromSide(ForgeDirection.getOrientation(0)).getTileEntity(worldObj);
if(tile instanceof ILogisticalTransporter)
if(bottomStack != null && isActive)
{
ILogisticalTransporter transporter = (ILogisticalTransporter)tile;
TileEntity tile = Coord4D.get(this).getFromSide(ForgeDirection.getOrientation(0)).getTileEntity(worldObj);
ItemStack rejects = TransporterUtils.insert(this, transporter, bottomStack, null, true, 0);
if(TransporterManager.didEmit(bottomStack, rejects))
if(tile instanceof ILogisticalTransporter)
{
setInventorySlotContents(0, rejects);
ILogisticalTransporter transporter = (ILogisticalTransporter)tile;
ItemStack rejects = TransporterUtils.insert(this, transporter, bottomStack, null, true, 0);
if(TransporterManager.didEmit(bottomStack, rejects))
{
setInventorySlotContents(0, rejects);
}
}
else if(tile instanceof IInventory)
{
setInventorySlotContents(0, InventoryUtils.putStackInInventory((IInventory)tile, bottomStack, 0, false));
}
delayTicks = 10;
}
else if(tile instanceof IInventory)
{
setInventorySlotContents(0, InventoryUtils.putStackInInventory((IInventory)tile, bottomStack, 0, false));
}
}
else {
delayTicks--;
}
}
}