}
harvestedBlockId = worldObj.getBlockId(targetCoords.x, targetCoords.y, targetCoords.z);
harvestedBlockMetadata = worldObj.getBlockMetadata(targetCoords.x, targetCoords.y, targetCoords.z);
IFactoryFruit harvestable = MFRRegistry.getFruits().get(new Integer(harvestedBlockId));
List<ItemStack> drops = harvestable.getDrops(worldObj, _rand, targetCoords.x, targetCoords.y, targetCoords.z);
ItemStack replacement = harvestable.getReplacementBlock(worldObj, targetCoords.x, targetCoords.y, targetCoords.z);
harvestable.prePick(worldObj, targetCoords.x, targetCoords.y, targetCoords.z);
doDrop(drops);
if(replacement == null)
{
if(MFRConfig.playSounds.getBoolean(true))
{
worldObj.playAuxSFXAtEntity(null, 2001, targetCoords.x, targetCoords.y, targetCoords.z, harvestedBlockId + (harvestedBlockMetadata << 12));
}
worldObj.setBlockToAir(targetCoords.x, targetCoords.y, targetCoords.z);
}
else
{
worldObj.setBlock(targetCoords.x, targetCoords.y, targetCoords.z, replacement.itemID, replacement.getItemDamage(), 3);
}
harvestable.postPick(worldObj, targetCoords.x, targetCoords.y, targetCoords.z);
return true;
}