public boolean onPlayerDestroyBlock(int par1, int par2, int par3, int par4)
    {
        ItemStack stack = mc.thePlayer.getCurrentEquippedItem();
        if (stack != null && stack.getItem().onBlockStartBreak(stack, par1, par2, par3, mc.thePlayer))
        {
            return false;
        }
        
        int var5 = this.mc.theWorld.getBlockId(par1, par2, par3);
        int var6 = this.mc.theWorld.getBlockMetadata(par1, par2, par3);
        boolean var7 = super.onPlayerDestroyBlock(par1, par2, par3, par4);
        ItemStack var8 = this.mc.thePlayer.getCurrentEquippedItem();
        boolean var9 = Block.blocksList[var5].canHarvestBlock(mc.thePlayer, var6);

        if (var8 != null)
        {
            var8.onDestroyBlock(var5, par1, par2, par3, this.mc.thePlayer);

            if (var8.stackSize == 0)
            {
                var8.onItemDestroyedByUse(this.mc.thePlayer);
                this.mc.thePlayer.destroyCurrentEquippedItem();
            }
        }

        if (var7 && var9)
        {
            Block.blocksList[var5].harvestBlock(this.mc.theWorld, this.mc.thePlayer, par1, par2, par3, var6);
        }

        return var7;
    }