Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## net.minecraft.item
Class ItemPotion

    java.lang.Object
      net.minecraft.item.Item
          net.minecraft.item.ItemPotion

    public class ItemPotion

extends Item

Field Summary

Fields inherited from class net.minecraft.item.Item
`appleGold, appleRed, arrow, axeDiamond, axeGold, axeSteel, axeStone, axeWood, bakedPotato, bed, beefCooked, beefRaw, blazePowder, blazeRod, boat, bone, book, bootsChain, bootsDiamond, bootsGold, bootsLeather, bootsSteel, bow, bowlEmpty, bowlSoup, bread, brewingStand, brick, bucketEmpty, bucketLava, bucketMilk, bucketWater, cake, carrot, carrotOnAStick, cauldron, chickenCooked, chickenRaw, clay, coal, compass, cookie, diamond, doorSteel, doorWood, dyePowder, egg, emerald, emptyMap, enderPearl, expBottle, eyeOfEnder, feather, fermentedSpiderEye, field_92052_bU, field_92053_bW, field_92054_bV, fireballCharge, fishCooked, fishingRod, fishRaw, flint, flintAndSteel, flowerPot, ghastTear, glassBottle, goldenCarrot, goldNugget, gunpowder, helmetChain, helmetDiamond, helmetGold, helmetLeather, helmetSteel, hoeDiamond, hoeGold, hoeSteel, hoeStone, hoeWood, ingotGold, ingotIron, isDefaultTexture, itemFrame, itemsList, leather, legsChain, legsDiamond, legsGold, legsLeather, legsSteel, lightStoneDust, magmaCream, map, melon, melonSeeds, minecartCrate, minecartEmpty, minecartPowered, monsterPlacer, netherStalkSeeds, netherStar, painting, paper, pickaxeDiamond, pickaxeGold, pickaxeSteel, pickaxeStone, pickaxeWood, plateChain, plateDiamond, plateGold, plateLeather, plateSteel, 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, shiftedIndex, shovelDiamond, shovelGold, shovelSteel, shovelStone, shovelWood, sign, silk, skull, slimeBall, snowball, speckledMelon, spiderEye, stick, sugar, swordDiamond, swordGold, swordSteel, swordStone, swordWood, wheat, writableBook, writtenBook`

Constructor Summary
`ItemPotion(int par1)`

Method Summary
`void` | `addInformation(ItemStack par1ItemStack, EntityPlayer par2EntityPlayer, List par3List, boolean par4)`
`int` | `getColorFromDamage(int par1)`
`int` | `getColorFromItemStack(ItemStack par1ItemStack, int par2)`
`List` | `getEffects(int par1)` Returns a list of effects for the specified potion damage value.
`List` | `getEffects(ItemStack par1ItemStack)` Returns a list of potion effects for the specified itemstack.
`int` | `getIconFromDamage(int par1)`
`int` | `getIconFromDamageForRenderPass(int par1, int par2)`
`String` | `getItemDisplayName(ItemStack par1ItemStack)`
`EnumAction` | `getItemUseAction(ItemStack par1ItemStack)` returns the action that specifies what animation to play when the items is being used
`int` | `getMaxItemUseDuration(ItemStack par1ItemStack)` How long it takes to use or consume an item
`void` | `getSubItems(int par1, CreativeTabs par2CreativeTabs, List par3List)`
`boolean` | `hasEffect(ItemStack par1ItemStack)`
`boolean` | `isEffectInstant(int par1)`
`static boolean` | `isSplash(int par0)` returns wether or not a potion is a throwable splash potion based on damage value
`ItemStack` | `onFoodEaten(ItemStack par1ItemStack, World par2World, EntityPlayer par3EntityPlayer)`
`ItemStack` | `onItemRightClick(ItemStack par1ItemStack, World par2World, EntityPlayer par3EntityPlayer)` Called whenever this item is equipped and the right mouse button is pressed.
`boolean` | `onItemUse(ItemStack par1ItemStack, EntityPlayer par2EntityPlayer, World par3World, int par4, int par5, int par6, int par7, float par8, float par9, float par10)` Callback for item usage.
`boolean` | `requiresMultipleRenderPasses()`

Methods inherited from class net.minecraft.item.Item
`canHarvestBlock, createEntity, doesContainerItemLeaveCraftingGrid, func_77653_i, func_82788_x, getChestGenBase, getContainerItem, getContainerItemStack, getCreativeTab, getCreativeTabs, getDamageVsEntity, getEntityLifespan, getHasSubtypes, getIconIndex, getIconIndex, getIconIndex, getIsRepairable, getItemEnchantability, getItemName, getItemNameIS, getItemStackLimit, getLocalItemName, getMaxDamage, getMetadata, getPotionEffect, getRarity, getRenderPasses, getShareTag, getSmeltingExperience, getStatName, getStrVsBlock, getStrVsBlock, getTextureFile, hasContainerItem, hasCustomEntity, hitEntity, isDamageable, isFull3D, isItemTool, isMap, isPotionIngredient, isRepairable, itemInteractionForEntity, onBlockDestroyed, onBlockStartBreak, onCreated, onDroppedByPlayer, onItemUseFirst, onLeftClickEntity, onPlayerStoppedUsing, onUpdate, onUsingItemTick, setContainerItem, setCreativeTab, setFull3D, setIconCoord, setIconIndex, setItemName, setMaxDamage, setMaxStackSize, setNoRepair, setTextureFile, shouldPassSneakingClickToBlock, shouldRotateAroundWhenRendering`

Methods inherited from class java.lang.Object
`equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### ItemPotion

    public ItemPotion(int par1)

Method Detail

### getEffects

    public List getEffects(ItemStack par1ItemStack)

  Returns a list of potion effects for the specified itemstack.

### getEffects

    public List getEffects(int par1)

  Returns a list of effects for the specified potion damage value.

### onFoodEaten

    public ItemStack onFoodEaten(ItemStack par1ItemStack,
                                 World par2World,
                                 EntityPlayer par3EntityPlayer)

  Overrides:
    `onFoodEaten` in class `Item`

### getMaxItemUseDuration

    public int getMaxItemUseDuration(ItemStack par1ItemStack)

  How long it takes to use or consume an item

  Overrides:
    `getMaxItemUseDuration` in class `Item`

### getItemUseAction

    public EnumAction getItemUseAction(ItemStack par1ItemStack)

  returns the action that specifies what animation to play when the items is being used

  Overrides:
    `getItemUseAction` in class `Item`

### 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:
    `onItemRightClick` in class `Item`

### onItemUse

    public boolean onItemUse(ItemStack par1ItemStack,
                             EntityPlayer par2EntityPlayer,
                             World par3World,
                             int par4,
                             int par5,
                             int par6,
                             int par7,
                             float par8,
                             float par9,
                             float par10)

  Callback for item usage. If the item does something special on right clicking, he will have one of those. Return True if something happen and false if it don't. This is for ITEMS, not BLOCKS

  Overrides:
    `onItemUse` in class `Item`

### getIconFromDamage

    public int getIconFromDamage(int par1)

  Overrides:
    `getIconFromDamage` in class `Item`

### getIconFromDamageForRenderPass

    public int getIconFromDamageForRenderPass(int par1,
                                              int par2)

  Overrides:
    `getIconFromDamageForRenderPass` in class `Item`

### isSplash

    public static boolean isSplash(int par0)

  returns wether or not a potion is a throwable splash potion based on damage value

### getColorFromDamage

    public int getColorFromDamage(int par1)

### getColorFromItemStack

    public int getColorFromItemStack(ItemStack par1ItemStack,
                                     int par2)

  Overrides:
    `getColorFromItemStack` in class `Item`

### requiresMultipleRenderPasses

    public boolean requiresMultipleRenderPasses()

  Overrides:
    `requiresMultipleRenderPasses` in class `Item`

### isEffectInstant

    public boolean isEffectInstant(int par1)

### getItemDisplayName

    public String getItemDisplayName(ItemStack par1ItemStack)

  Overrides:
    `getItemDisplayName` in class `Item`

### addInformation

    public void addInformation(ItemStack par1ItemStack,
                               EntityPlayer par2EntityPlayer,
                               List par3List,
                               boolean par4)

  Overrides:
    `addInformation` in class `Item`

### hasEffect

    public boolean hasEffect(ItemStack par1ItemStack)

  Overrides:
    `hasEffect` in class `Item`

### getSubItems

    public void getSubItems(int par1,
                            CreativeTabs par2CreativeTabs,
                            List par3List)

  Overrides:
    `getSubItems` in class `Item`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD