net.minecraft.item

## Class ItemTool

- java.lang.Object
- - net.minecraft.item.Item
  - - net.minecraft.item.ItemTool

- Direct Known Subclasses:
    ItemAxe, ItemPickaxe, ItemSpade

      public class ItemTool
      extends Item

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `float` | `damageVsEntity` Damage versus entities.
    `float` | `efficiencyOnProperMaterial`

    - ### Fields inherited from class net.minecraft.item.Item

      `appleGold, appleRed, arrow, axeDiamond, axeGold, axeIron, axeStone, axeWood, bakedPotato, bed, beefCooked, beefRaw, blazePowder, blazeRod, boat, bone, book, bootsChain, bootsDiamond, bootsGold, bootsIron, bootsLeather, bow, bowlEmpty, bowlSoup, bread, brewingStand, brick, bucketEmpty, bucketLava, bucketMilk, bucketWater, cake, carrot, carrotOnAStick, cauldron, chickenCooked, chickenRaw, clay, coal, comparator, compass, cookie, diamond, doorIron, doorWood, dyePowder, egg, emerald, emptyMap, enchantedBook, enderPearl, expBottle, eyeOfEnder, feather, fermentedSpiderEye, fireballCharge, firework, fireworkCharge, fishCooked, fishingRod, fishRaw, flint, flintAndSteel, flowerPot, ghastTear, glassBottle, glowstone, goldenCarrot, goldNugget, gunpowder, helmetChain, helmetDiamond, helmetGold, helmetIron, helmetLeather, hoeDiamond, hoeGold, hoeIron, hoeStone, hoeWood, horseArmorDiamond, horseArmorGold, horseArmorIron, ingotGold, ingotIron, itemFrame, itemID, itemsList, leash, leather, legsChain, legsDiamond, legsGold, legsIron, legsLeather, magmaCream, map, melon, melonSeeds, minecartCrate, minecartEmpty, minecartHopper, minecartPowered, minecartTnt, monsterPlacer, nameTag, netherQuartz, netherrackBrick, netherStalkSeeds, netherStar, painting, paper, pickaxeDiamond, pickaxeGold, pickaxeIron, pickaxeStone, pickaxeWood, plateChain, plateDiamond, plateGold, plateIron, plateLeather, pocketSundial, poisonousPotato, porkCooked, porkRaw, potato, potion, pumpkinPie, pumpkinSeeds, record11, record13, recordBlocks, recordCat, recordChirp, recordFar, recordMall, recordMellohi, recordStal, recordStrad, recordWait, recordWard, redstone, redstoneRepeater, reed, rottenFlesh, saddle, seeds, shears, shovelDiamond, shovelGold, shovelIron, shovelStone, shovelWood, sign, silk, skull, slimeBall, snowball, speckledMelon, spiderEye, stick, sugar, swordDiamond, swordGold, swordIron, swordStone, swordWood, wheat, writableBook, writtenBook`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `boolean` | `getIsRepairable(ItemStack par1ItemStack, ItemStack par2ItemStack)` Return whether this item is repairable in an anvil.
    `com.google.common.collect.Multimap` | `getItemAttributeModifiers()` Gets a map of item attribute modifiers, used by ItemSword to increase hit damage.
    `int` | `getItemEnchantability()` Return the enchantability factor of the item, most of the time is based on material.
    `float` | `getStrVsBlock(ItemStack par1ItemStack, Block par2Block)` Returns the strength of the stack against a given block.
    `float` | `getStrVsBlock(ItemStack stack, Block block, int meta)` FORGE: Overridden to allow custom tool effectiveness
    `String` | `getToolMaterialName()` Return the name for this tool's material.
    `boolean` | `hitEntity(ItemStack par1ItemStack, EntityLivingBase par2EntityLivingBase, EntityLivingBase par3EntityLivingBase)` Current implementations of this method in child classes do not use the entry argument beside ev.
    `boolean` | `isFull3D()`
    `boolean` | `onBlockDestroyed(ItemStack par1ItemStack, World par2World, int par3, int par4, int par5, int par6, EntityLivingBase par7EntityLivingBase)`

    - ### Methods inherited from class net.minecraft.item.Item

      `addInformation, canHarvestBlock, canHarvestBlock, canItemEditBlocks, createEntity, doesContainerItemLeaveCraftingGrid, getArmorModel, getArmorTexture, getArmorTexture, getChestGenBase, getColorFromItemStack, getContainerItem, getContainerItemStack, getCreativeTab, getCreativeTabs, getDamage, getDamageVsEntity, getDisplayDamage, getEntityLifespan, getFontRenderer, getHasSubtypes, getIcon, getIcon, getIconFromDamage, getIconFromDamageForRenderPass, getIconIndex, getItemDisplayName, getItemStackDisplayName, getItemStackLimit, getItemUseAction, getMaxDamage, getMaxDamage, getMaxItemUseDuration, getMetadata, getPotionEffect, getPotionEffect, getRarity, getRenderPasses, getShareTag, getSmeltingExperience, getSpriteNumber, getStatName, getSubItems, getUnlocalizedName, getUnlocalizedName, getUnlocalizedNameInefficiently, hasContainerItem, hasCustomEntity, hasEffect, hasEffect, isBookEnchantable, isDamageable, isDamaged, isItemTool, isMap, isPotionIngredient, isPotionIngredient, isRepairable, isValidArmor, itemInteractionForEntity, onArmorTickUpdate, onBlockStartBreak, onCreated, onDroppedByPlayer, onEaten, onEntityItemUpdate, onEntitySwing, onItemRightClick, onItemUse, onItemUseFirst, onLeftClickEntity, onPlayerStoppedUsing, onUpdate, onUsingItemTick, registerIcons, renderHelmetOverlay, requiresMultipleRenderPasses, setContainerItem, setCreativeTab, setDamage, setFull3D, setMaxDamage, setMaxStackSize, setNoRepair, setPotionEffect, setTextureName, setUnlocalizedName, shouldPassSneakingClickToBlock, shouldRotateAroundWhenRendering`

    - ### Methods inherited from class java.lang.Object

      `equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Field Detail

    - #### efficiencyOnProperMaterial

          public float efficiencyOnProperMaterial

    - #### damageVsEntity

          public float damageVsEntity

      Damage versus entities.

  - ### Method Detail

    - #### getStrVsBlock

          public float getStrVsBlock(ItemStack par1ItemStack,
                            Block par2Block)

      Returns the strength of the stack against a given block. 1.0F base, (Quality+1)*2 if correct blocktype, 1.5F if sword
      Overrides:
        `getStrVsBlock` in class `Item`

    - #### hitEntity

          public boolean hitEntity(ItemStack par1ItemStack,
                          EntityLivingBase par2EntityLivingBase,
                          EntityLivingBase par3EntityLivingBase)

      Current implementations of this method in child classes do not use the entry argument beside ev. They just raise the damage on the stack.
      Overrides:
        `hitEntity` in class `Item`

    - #### onBlockDestroyed

          public boolean onBlockDestroyed(ItemStack par1ItemStack,
                                 World par2World,
                                 int par3,
                                 int par4,
                                 int par5,
                                 int par6,
                                 EntityLivingBase par7EntityLivingBase)

      Overrides:
        `onBlockDestroyed` in class `Item`

    - #### isFull3D

          public boolean isFull3D()

      Overrides:
        `isFull3D` in class `Item`

    - #### getItemEnchantability

          public int getItemEnchantability()

      Return the enchantability factor of the item, most of the time is based on material.
      Overrides:
        `getItemEnchantability` in class `Item`

    - #### getToolMaterialName

          public String getToolMaterialName()

      Return the name for this tool's material.

    - #### getIsRepairable

          public boolean getIsRepairable(ItemStack par1ItemStack,
                                ItemStack par2ItemStack)

      Return whether this item is repairable in an anvil.
      Overrides:
        `getIsRepairable` in class `Item`

    - #### getItemAttributeModifiers

          public com.google.common.collect.Multimap getItemAttributeModifiers()

      Gets a map of item attribute modifiers, used by ItemSword to increase hit damage.
      Overrides:
        `getItemAttributeModifiers` in class `Item`

    - #### getStrVsBlock

          public float getStrVsBlock(ItemStack stack,
                            Block block,
                            int meta)

      FORGE: Overridden to allow custom tool effectiveness
      Overrides:
        `getStrVsBlock` in class `Item`
      Parameters:
        `stack` - The Item Stack
        `block` - The block the item is trying to break
        `meta` - The items current metadata
      Returns:
        The damage strength