Mekanism-tilera-Edition/common/buildcraft/api/bptblocks/BptBlockRotateInventory.java

28 lines
697 B
Java
Raw Normal View History

package buildcraft.api.bptblocks;
import buildcraft.api.blueprints.BptSlotInfo;
import buildcraft.api.blueprints.IBptContext;
2013-08-08 19:10:11 +02:00
import net.minecraft.inventory.IInventory;
@Deprecated
public class BptBlockRotateInventory extends BptBlockRotateMeta {
public BptBlockRotateInventory(int blockId, int[] rotations, boolean rotateForward) {
super(blockId, rotations, rotateForward);
}
@Override
public void buildBlock(BptSlotInfo slot, IBptContext context) {
super.buildBlock(slot, context);
IInventory inv = (IInventory) context.world().getBlockTileEntity(slot.x, slot.y, slot.z);
for (int i = 0; i < inv.getSizeInventory(); ++i) {
inv.setInventorySlotContents(i, null);
}
}
}