Class Potion

java.lang.Object
net.minecraft.src.Potion
Direct Known Subclasses:
PotionAbsoption, PotionAttackDamage, PotionHealth, PotionHealthBoost

public class Potion extends Object
  • Field Details

    • potionTypes

      public static final Potion[] potionTypes
      The array of potion types.
    • field_76423_b

      public static final Potion field_76423_b
    • moveSpeed

      public static final Potion moveSpeed
    • moveSlowdown

      public static final Potion moveSlowdown
    • digSpeed

      public static final Potion digSpeed
    • digSlowdown

      public static final Potion digSlowdown
    • damageBoost

      public static final Potion damageBoost
    • heal

      public static final Potion heal
    • harm

      public static final Potion harm
    • jump

      public static final Potion jump
    • confusion

      public static final Potion confusion
    • regeneration

      public static final Potion regeneration
      The regeneration Potion object.
    • resistance

      public static final Potion resistance
    • fireResistance

      public static final Potion fireResistance
      The fire resistance Potion object.
    • waterBreathing

      public static final Potion waterBreathing
      The water breathing Potion object.
    • invisibility

      public static final Potion invisibility
      The invisibility Potion object.
    • blindness

      public static final Potion blindness
      The blindness Potion object.
    • nightVision

      public static final Potion nightVision
      The night vision Potion object.
    • hunger

      public static final Potion hunger
      The hunger Potion object.
    • weakness

      public static final Potion weakness
      The weakness Potion object.
    • poison

      public static final Potion poison
      The poison Potion object.
    • wither

      public static final Potion wither
      The wither Potion object.
    • field_76434_w

      public static final Potion field_76434_w
    • field_76444_x

      public static final Potion field_76444_x
    • field_76443_y

      public static final Potion field_76443_y
    • field_76442_z

      public static final Potion field_76442_z
    • field_76409_A

      public static final Potion field_76409_A
    • field_76410_B

      public static final Potion field_76410_B
    • field_76411_C

      public static final Potion field_76411_C
    • field_76405_D

      public static final Potion field_76405_D
    • field_76406_E

      public static final Potion field_76406_E
    • field_76407_F

      public static final Potion field_76407_F
    • field_76408_G

      public static final Potion field_76408_G
    • id

      public final int id
      The Id of a Potion object.
    • liquidColor

      public int liquidColor
      Is the color of the liquid for this potion.
    • name

      public String name
      The name of the Potion.
    • origColor

      @Environment(CLIENT) public int origColor
    • tickEveryBase

      protected int tickEveryBase
  • Constructor Details

    • Potion

      public Potion(int par1, boolean par2, int par3)
    • Potion

      public Potion(int par1, boolean par2, int par3, int tickEveryBase)
  • Method Details

    • setIconIndex

      public Potion setIconIndex(int par1, int par2)
      Sets the index for the icon displayed in the player's inventory when the status is active.
    • getId

      public int getId()
      returns the ID of the potion
    • performEffect

      public void performEffect(EntityLivingBase par1EntityLivingBase, int par2)
    • affectEntity

      public void affectEntity(EntityLivingBase par1EntityLivingBase, EntityLivingBase par2EntityLivingBase, int par3, double par4)
      Hits the provided entity with this potion's instant effect.
    • isInstant

      public boolean isInstant()
      Returns true if the potion has an instant effect instead of a continuous one (eg Harming)
    • isReady

      public boolean isReady(int par1, int par2)
      checks if Potion effect is ready to be applied this tick.
    • setPotionName

      public Potion setPotionName(String par1Str)
      Set the potion name.
    • getName

      public String getName()
      returns the name of the potion
    • hasStatusIcon

      public boolean hasStatusIcon()
      Returns true if the potion has a associated status icon to display in then inventory when active.
    • getStatusIconIndex

      public int getStatusIconIndex()
      Returns the index for the icon to display when the potion is active.
    • isBadEffect

      public boolean isBadEffect()
      This method returns true if the potion effect is bad - negative - for the entity.
    • getDurationString

      public static String getDurationString(PotionEffect par0PotionEffect)
    • setEffectiveness

      protected Potion setEffectiveness(double par1)
    • getEffectiveness

      public double getEffectiveness()
    • isUsable

      public boolean isUsable()
    • getLiquidColor

      public int getLiquidColor()
      Returns the color of the potion liquid.
    • func_111184_a

      public Potion func_111184_a(Attribute par1Attribute, String par2Str, double par3, int par5)
    • func_111186_k

      public Map func_111186_k()
    • removeAttributesModifiersFromEntity

      public void removeAttributesModifiersFromEntity(EntityLivingBase par1EntityLivingBase, BaseAttributeMap par2BaseAttributeMap, int par3)
    • applyAttributesModifiersToEntity

      public void applyAttributesModifiersToEntity(EntityLivingBase par1EntityLivingBase, BaseAttributeMap par2BaseAttributeMap, int par3)
    • func_111183_a

      public double func_111183_a(int par1, AttributeModifier par2AttributeModifier)
    • getTickEveryBase

      public int getTickEveryBase()