Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- @Override
- public void updateEntity() {
- List<EntityItem> list = this.worldObj.getEntitiesWithinAABB(EntityItem.class, AxisAlignedBB.getBoundingBox(blockType.minX, blockType.minY, blockType.minZ, blockType.maxX, blockType.maxY, blockType.maxZ));
- for (EntityItem entityItem : list) {
- if (entityItem != null && !entityItem.isDead && !this.worldObj.isRemote && entityItem.delayBeforeCanPickup == 0) {
- addItemStackToInventory(entityItem.item.copy());
- entityItem.setDead();
- }
- }
- super.updateEntity();
- }
Advertisement