org.bukkit.potion
Enum PotionType
java.lang.Object
java.lang.Enum<PotionType>
org.bukkit.potion.PotionType
- All Implemented Interfaces:
- Serializable, Comparable<PotionType>
public enum PotionType
- extends Enum<PotionType>
WATER
public static final PotionType WATER
REGEN
public static final PotionType REGEN
SPEED
public static final PotionType SPEED
FIRE_RESISTANCE
public static final PotionType FIRE_RESISTANCE
POISON
public static final PotionType POISON
INSTANT_HEAL
public static final PotionType INSTANT_HEAL
NIGHT_VISION
public static final PotionType NIGHT_VISION
WEAKNESS
public static final PotionType WEAKNESS
STRENGTH
public static final PotionType STRENGTH
SLOWNESS
public static final PotionType SLOWNESS
INSTANT_DAMAGE
public static final PotionType INSTANT_DAMAGE
INVISIBILITY
public static final PotionType INVISIBILITY
values
public static final PotionType[] values()
- Returns an array containing the constants of this enum type, in
the order they're declared. This method may be used to iterate
over the constants as follows:
for(PotionType c : PotionType.values())
System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in
the order they're declared
valueOf
public static PotionType valueOf(String name)
- Returns the enum constant of this type with the specified name.
The string must match exactly an identifier used to declare an
enum constant in this type. (Extraneous whitespace characters are
not permitted.)
- Parameters:
name
- the name of the enum constant to be returned.
- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum type has no constant
with the specified name
getEffectType
public PotionEffectType getEffectType()
getDamageValue
public int getDamageValue()
getMaxLevel
public int getMaxLevel()
isInstant
public boolean isInstant()
getByDamageValue
public static PotionType getByDamageValue(int damage)
getByEffect
public static PotionType getByEffect(PotionEffectType effectType)
Copyright © 2013. All Rights Reserved.