Package net.minecraft.src
Class ItemSword
java.lang.Object
net.minecraft.src.Item
net.minecraft.src.ItemSword
- Direct Known Subclasses:
SwordItem
-
Field Summary
Fields inherited from class net.minecraft.src.Item
appleGold, appleRed, arrow, axeDiamond, axeGold, axeIron, axeStone, axeWood, bakedPotato, BASE_CHICKEN_ITEM_FOOD_VALUE, BASE_HERBIVORE_ITEM_FOOD_VALUE, BASE_PIG_ITEM_FOOD_VALUE, bed, beefCooked, beefRaw, bFull3D, 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, defaultFurnaceBurnTime, diamond, doorIron, doorWood, dyePowder, egg, emerald, emptyMap, enchantedBook, enderPearl, expBottle, eyeOfEnder, feather, fermentedSpiderEye, field_111210_e, FILTERABLE_FINE, FILTERABLE_NARROW, FILTERABLE_NO_PROPERTIES, FILTERABLE_SMALL, FILTERABLE_SOLID_BLOCK, FILTERABLE_THIN, fireballCharge, firework, fireworkCharge, fishCooked, fishingRod, fishRaw, flint, flintAndSteel, flowerPot, ghastTear, glassBottle, glowstone, goldenCarrot, goldNugget, gunpowder, hasSubtypes, helmetChain, helmetDiamond, helmetGold, helmetIron, helmetLeather, hoeDiamond, hoeGold, hoeIron, hoeStone, hoeWood, horseArmorDiamond, horseArmorGold, horseArmorIron, iconString, ingotGold, ingotIron, isInceratedInCrucible, itemFrame, itemIcon, itemID, itemRand, itemsList, leash, leather, legsChain, legsDiamond, legsGold, legsIron, legsLeather, magmaCream, map, maxStackSize, melon, melonSeeds, minecartCrate, minecartEmpty, minecartHopper, minecartPowered, minecartTnt, modID, modIDSetter, 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, suppressConflictWarnings, swordDiamond, swordGold, swordIron, swordStone, swordWood, wheat, writableBook, writtenBook -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleancanHarvestBlock(Block par1Block) Returns if the item (tool) can harvest results from the block type.floatbooleangetIsRepairable(ItemStack par1ItemStack, ItemStack par2ItemStack) Return whether this item is repairable in an anvil.com.google.common.collect.MultimapGets a map of item attribute modifiers, used by ItemSword to increase hit damage.intReturn the enchantability factor of the item, most of the time is based on material.getItemUseAction(ItemStack par1ItemStack) returns the action that specifies what animation to play when the items is being usedintgetMaxItemUseDuration(ItemStack par1ItemStack) How long it takes to use or consume an itemfloatgetStrVsBlock(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 swordReturn the name for this tool's material.booleanhitEntity(ItemStack par1ItemStack, EntityLivingBase par2EntityLivingBase, EntityLivingBase par3EntityLivingBase) Current implementations of this method in child classes do not use the entry argument beside ev.booleanisFull3D()Returns True is the item is renderer in full 3D when hold.booleanonBlockDestroyed(ItemStack par1ItemStack, World par2World, int par3, int par4, int par5, int par6, EntityLivingBase par7EntityLivingBase) onItemRightClick(ItemStack par1ItemStack, World par2World, EntityPlayer par3EntityPlayer) Called whenever this item is equipped and the right mouse button is pressed.Methods inherited from class net.minecraft.src.Item
addInformation, canHarvestBlock, canItemBeUsedByPlayer, canItemEditBlocks, createItemAsEntityInWorld, doesConsumeContainerItemWhenCrafted, doesContainerItemLeaveCraftingGrid, doZombiesConsume, getAnimationIcon, getBuoyancy, getCampfireBurnTime, getCanBeFedDirectlyIntoBrickOven, getCanBeFedDirectlyIntoCampfire, getCanItemBeSetOnFireOnUse, getCanItemStartFireOnUse, getChickenFoodValue, getColorFromItemStack, getContainerItem, getCreativeTab, getCustomItemEntity, getExhaustionOnUsedToHarvestBlock, getFurnaceBurnTime, getHasSubtypes, getHerbivoreFoodValue, getHopperFilterIcon, getIconFromDamage, getIconFromDamageForRenderPass, getIconIndex, getIconString, getInfernalMaxEnchantmentCost, getInfernalMaxNumEnchants, getItemDisplayName, getItemRightClickCooldown, getItemStackDisplayName, getItemStackLimit, getItemUseWarmupDuration, getMaxDamage, getMetadata, getModId, getMovingObjectPositionFromPlayer, getPigFoodValue, getPotionEffect, getRarity, getShareTag, getSpriteNumber, getStatName, getStrVsBlock, getSubItems, getUnlocalizedName, getUnlocalizedName, getUnlocalizedNameInefficiently, getWolfHealAmount, hasContainerItem, hasCustomItemEntity, hasEffect, hideFromEMI, ignoreDamageWhenComparingDuringUse, initializeStackOnGiveCommand, isConsumedInCrafting, isDamageable, isDamagedInCrafting, isEfficientVsBlock, isEnchantmentApplicable, isIncineratedInCrucible, isItemTool, isMap, isMultiUsePerClick, isPotionIngredient, isWolfFood, itemInteractionForEntity, onBrokenInCrafting, onCreated, onDamagedInCrafting, onEaten, onItemUse, onItemUsedByBlockDispenser, onPlayerStoppedUsing, onUpdate, onUsedInCrafting, onUsedInCrafting, registerIcons, requiresMultipleRenderPasses, setAllAxesToBeEffectiveVsBlock, setAllPicksToBeEffectiveVsBlock, setAllShovelsToBeEffectiveVsBlock, setAsBasicChickenFood, setAsBasicHerbivoreFood, setAsBasicPigFood, setBuoyancy, setBuoyant, setChickenFoodValue, setContainerItem, setCreativeTab, setCustomItemEntity, setFull3D, setfurnaceburntime, setfurnaceburntime, setHasSubtypes, setHerbivoreFoodValue, setIncineratedInCrucible, setInfernalMaxEnchantmentCost, setInfernalMaxNumEnchants, setItemRightClickCooldown, setMaxDamage, setMaxStackSize, setModID, setNeutralBuoyant, setNonBuoyant, setNotIncineratedInCrucible, setPigFoodValue, setPotionEffect, setTextureName, setUnlocalizedName, shouldApplyAttributesWhenHeld, shouldApplyAttributesWhenWorn, shouldRotateAroundWhenRendering, updateUsingItem
-
Constructor Details
-
ItemSword
-
-
Method Details
-
func_82803_g
public float func_82803_g() -
getStrVsBlock
Returns the strength of the stack against a given block. 1.0F base, (Quality+1)*2 if correct blocktype, 1.5F if sword -
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. -
onBlockDestroyed
public boolean onBlockDestroyed(ItemStack par1ItemStack, World par2World, int par3, int par4, int par5, int par6, EntityLivingBase par7EntityLivingBase) - Overrides:
onBlockDestroyedin classItem
-
isFull3D
public boolean isFull3D()Returns True is the item is renderer in full 3D when hold. -
getItemUseAction
returns the action that specifies what animation to play when the items is being used- Overrides:
getItemUseActionin classItem
-
getMaxItemUseDuration
How long it takes to use or consume an item- Overrides:
getMaxItemUseDurationin classItem
-
onItemRightClick
public ItemStack onItemRightClick(ItemStack par1ItemStack, World par2World, EntityPlayer par3EntityPlayer) Called whenever this item is equipped and the right mouse button is pressed. Args: itemStack, world, entityPlayer- Overrides:
onItemRightClickin classItem
-
canHarvestBlock
Returns if the item (tool) can harvest results from the block type. -
getItemEnchantability
public int getItemEnchantability()Return the enchantability factor of the item, most of the time is based on material.- Overrides:
getItemEnchantabilityin classItem
-
getToolMaterialName
Return the name for this tool's material. -
getIsRepairable
Return whether this item is repairable in an anvil.- Overrides:
getIsRepairablein classItem
-
getItemAttributeModifiers
public com.google.common.collect.Multimap getItemAttributeModifiers()Gets a map of item attribute modifiers, used by ItemSword to increase hit damage.- Overrides:
getItemAttributeModifiersin classItem
-