Skip to content

Potion

endstone.potion

Classes relating to potion effects.

Classes:

Name Description
Effect

Represents an effect that can be added to a Mob.

EffectType

Represents an effect type.

PotionType

Represents a potion type.

Effect

Effect(
    type: Identifier[EffectType] | str,
    duration: int | None,
    amplifier: int,
    ambient: bool = False,
    particles: bool = True,
    icon: bool = True,
)

Represents an effect that can be added to a Mob.

Creates an effect. A duration of None represents an infinite duration.

Attributes:

Name Type Description
ambient bool

Whether this effect produces more, translucent, particles.

amplifier int

Gets the amplifier of this effect.

duration int | None

Gets the duration of this effect in ticks, or None if this effect is infinite.

icon bool

Whether this effect has an icon.

infinite bool

Whether this effect has an infinite duration.

particles bool

Whether this effect has particles.

type Identifier[EffectType]

Gets the type of this effect.

ambient property

ambient: bool

Whether this effect produces more, translucent, particles.

amplifier property

amplifier: int

Gets the amplifier of this effect.

duration property

duration: int | None

Gets the duration of this effect in ticks, or None if this effect is infinite.

icon property

icon: bool

Whether this effect has an icon.

infinite property

infinite: bool

Whether this effect has an infinite duration.

particles property

particles: bool

Whether this effect has particles.

type property

type: Identifier[EffectType]

Gets the type of this effect.

EffectType

Represents an effect type.

Methods:

Name Description
get

Attempts to get the EffectType with the given name.

Attributes:

Name Type Description
ABSORPTION Identifier[EffectType]
BAD_OMEN Identifier[EffectType]
BLINDNESS Identifier[EffectType]
BREATH_OF_THE_NAUTILUS Identifier[EffectType]
CONDUIT_POWER Identifier[EffectType]
DARKNESS Identifier[EffectType]
FATAL_POISON Identifier[EffectType]
FIRE_RESISTANCE Identifier[EffectType]
HASTE Identifier[EffectType]
HEALTH_BOOST Identifier[EffectType]
HUNGER Identifier[EffectType]
INFESTED Identifier[EffectType]
INSTANT_DAMAGE Identifier[EffectType]
INSTANT_HEALTH Identifier[EffectType]
INVISIBILITY Identifier[EffectType]
JUMP_BOOST Identifier[EffectType]
LEVITATION Identifier[EffectType]
MINING_FATIGUE Identifier[EffectType]
NAUSEA Identifier[EffectType]
NIGHT_VISION Identifier[EffectType]
OOZING Identifier[EffectType]
POISON Identifier[EffectType]
RAID_OMEN Identifier[EffectType]
REGENERATION Identifier[EffectType]
RESISTANCE Identifier[EffectType]
SATURATION Identifier[EffectType]
SLOWNESS Identifier[EffectType]
SLOW_FALLING Identifier[EffectType]
SPEED Identifier[EffectType]
STRENGTH Identifier[EffectType]
TRIAL_OMEN Identifier[EffectType]
VILLAGE_HERO Identifier[EffectType]
WATER_BREATHING Identifier[EffectType]
WEAKNESS Identifier[EffectType]
WEAVING Identifier[EffectType]
WIND_CHARGED Identifier[EffectType]
WITHER Identifier[EffectType]
id Identifier[EffectType]

The identifier of this effect type.

translation_key str

The translation key, suitable for use in a translation component.

ABSORPTION class-attribute instance-attribute

ABSORPTION: Identifier[EffectType] = 'minecraft:absorption'

BAD_OMEN class-attribute instance-attribute

BAD_OMEN: Identifier[EffectType] = 'minecraft:bad_omen'

BLINDNESS class-attribute instance-attribute

BLINDNESS: Identifier[EffectType] = 'minecraft:blindness'

BREATH_OF_THE_NAUTILUS class-attribute instance-attribute

BREATH_OF_THE_NAUTILUS: Identifier[EffectType] = (
    "minecraft:breath_of_the_nautilus"
)

CONDUIT_POWER class-attribute instance-attribute

CONDUIT_POWER: Identifier[EffectType] = (
    "minecraft:conduit_power"
)

DARKNESS class-attribute instance-attribute

DARKNESS: Identifier[EffectType] = 'minecraft:darkness'

FATAL_POISON class-attribute instance-attribute

FATAL_POISON: Identifier[EffectType] = (
    "minecraft:fatal_poison"
)

FIRE_RESISTANCE class-attribute instance-attribute

FIRE_RESISTANCE: Identifier[EffectType] = (
    "minecraft:fire_resistance"
)

HASTE class-attribute instance-attribute

HASTE: Identifier[EffectType] = 'minecraft:haste'

HEALTH_BOOST class-attribute instance-attribute

HEALTH_BOOST: Identifier[EffectType] = (
    "minecraft:health_boost"
)

HUNGER class-attribute instance-attribute

HUNGER: Identifier[EffectType] = 'minecraft:hunger'

INFESTED class-attribute instance-attribute

INFESTED: Identifier[EffectType] = 'minecraft:infested'

INSTANT_DAMAGE class-attribute instance-attribute

INSTANT_DAMAGE: Identifier[EffectType] = (
    "minecraft:instant_damage"
)

INSTANT_HEALTH class-attribute instance-attribute

INSTANT_HEALTH: Identifier[EffectType] = (
    "minecraft:instant_health"
)

INVISIBILITY class-attribute instance-attribute

INVISIBILITY: Identifier[EffectType] = (
    "minecraft:invisibility"
)

JUMP_BOOST class-attribute instance-attribute

JUMP_BOOST: Identifier[EffectType] = 'minecraft:jump_boost'

LEVITATION class-attribute instance-attribute

LEVITATION: Identifier[EffectType] = 'minecraft:levitation'

MINING_FATIGUE class-attribute instance-attribute

MINING_FATIGUE: Identifier[EffectType] = (
    "minecraft:mining_fatigue"
)

NAUSEA class-attribute instance-attribute

NAUSEA: Identifier[EffectType] = 'minecraft:nausea'

NIGHT_VISION class-attribute instance-attribute

NIGHT_VISION: Identifier[EffectType] = (
    "minecraft:night_vision"
)

OOZING class-attribute instance-attribute

OOZING: Identifier[EffectType] = 'minecraft:oozing'

POISON class-attribute instance-attribute

POISON: Identifier[EffectType] = 'minecraft:poison'

RAID_OMEN class-attribute instance-attribute

RAID_OMEN: Identifier[EffectType] = 'minecraft:raid_omen'

REGENERATION class-attribute instance-attribute

REGENERATION: Identifier[EffectType] = (
    "minecraft:regeneration"
)

RESISTANCE class-attribute instance-attribute

RESISTANCE: Identifier[EffectType] = 'minecraft:resistance'

SATURATION class-attribute instance-attribute

SATURATION: Identifier[EffectType] = 'minecraft:saturation'

SLOWNESS class-attribute instance-attribute

SLOWNESS: Identifier[EffectType] = 'minecraft:slowness'

SLOW_FALLING class-attribute instance-attribute

SLOW_FALLING: Identifier[EffectType] = (
    "minecraft:slow_falling"
)

SPEED class-attribute instance-attribute

SPEED: Identifier[EffectType] = 'minecraft:speed'

STRENGTH class-attribute instance-attribute

STRENGTH: Identifier[EffectType] = 'minecraft:strength'

TRIAL_OMEN class-attribute instance-attribute

TRIAL_OMEN: Identifier[EffectType] = 'minecraft:trial_omen'

VILLAGE_HERO class-attribute instance-attribute

VILLAGE_HERO: Identifier[EffectType] = (
    "minecraft:village_hero"
)

WATER_BREATHING class-attribute instance-attribute

WATER_BREATHING: Identifier[EffectType] = (
    "minecraft:water_breathing"
)

WEAKNESS class-attribute instance-attribute

WEAKNESS: Identifier[EffectType] = 'minecraft:weakness'

WEAVING class-attribute instance-attribute

WEAVING: Identifier[EffectType] = 'minecraft:weaving'

WIND_CHARGED class-attribute instance-attribute

WIND_CHARGED: Identifier[EffectType] = (
    "minecraft:wind_charged"
)

WITHER class-attribute instance-attribute

WITHER: Identifier[EffectType] = 'minecraft:wither'

id property

id: Identifier[EffectType]

The identifier of this effect type.

translation_key property

translation_key: str

The translation key, suitable for use in a translation component.

get staticmethod

get(name: Identifier[EffectType] | str) -> EffectType

Attempts to get the EffectType with the given name.

Parameters:

Name Type Description Default
name Identifier[EffectType] | str

The identifier of the effect type (e.g. minecraft:speed).

required

Returns:

Type Description
EffectType

The EffectType, or None if no effect type with that name exists.

PotionType

Represents a potion type.

Methods:

Name Description
get

Attempts to get the PotionType with the given name.

Attributes:

Name Type Description
AWKWARD Identifier[PotionType]
FIRE_RESISTANCE Identifier[PotionType]
HARMING Identifier[PotionType]
HEALING Identifier[PotionType]
INFESTED Identifier[PotionType]
INVISIBILITY Identifier[PotionType]
LEAPING Identifier[PotionType]
LONG_FIRE_RESISTANCE Identifier[PotionType]
LONG_INVISIBILITY Identifier[PotionType]
LONG_LEAPING Identifier[PotionType]
LONG_MUNDANE Identifier[PotionType]
LONG_NIGHTVISION Identifier[PotionType]
LONG_POISON Identifier[PotionType]
LONG_REGENERATION Identifier[PotionType]
LONG_SLOWNESS Identifier[PotionType]
LONG_SLOW_FALLING Identifier[PotionType]
LONG_STRENGTH Identifier[PotionType]
LONG_SWIFTNESS Identifier[PotionType]
LONG_TURTLE_MASTER Identifier[PotionType]
LONG_WATER_BREATHING Identifier[PotionType]
LONG_WEAKNESS Identifier[PotionType]
MUNDANE Identifier[PotionType]
NIGHTVISION Identifier[PotionType]
OOZING Identifier[PotionType]
POISON Identifier[PotionType]
REGENERATION Identifier[PotionType]
SLOWNESS Identifier[PotionType]
SLOW_FALLING Identifier[PotionType]
STRENGTH Identifier[PotionType]
STRONG_HARMING Identifier[PotionType]
STRONG_HEALING Identifier[PotionType]
STRONG_LEAPING Identifier[PotionType]
STRONG_POISON Identifier[PotionType]
STRONG_REGENERATION Identifier[PotionType]
STRONG_SLOWNESS Identifier[PotionType]
STRONG_STRENGTH Identifier[PotionType]
STRONG_SWIFTNESS Identifier[PotionType]
STRONG_TURTLE_MASTER Identifier[PotionType]
SWIFTNESS Identifier[PotionType]
THICK Identifier[PotionType]
TURTLE_MASTER Identifier[PotionType]
WATER Identifier[PotionType]
WATER_BREATHING Identifier[PotionType]
WEAKNESS Identifier[PotionType]
WEAVING Identifier[PotionType]
WIND_CHARGED Identifier[PotionType]
WITHER Identifier[PotionType]
id Identifier[PotionType]

The identifier of this potion type.

translation_key str

The translation key, suitable for use in a translation component.

AWKWARD class-attribute instance-attribute

AWKWARD: Identifier[PotionType] = (
    "minecraft:potion_type:awkward"
)

FIRE_RESISTANCE class-attribute instance-attribute

FIRE_RESISTANCE: Identifier[PotionType] = (
    "minecraft:potion_type:fire_resistance"
)

HARMING class-attribute instance-attribute

HARMING: Identifier[PotionType] = (
    "minecraft:potion_type:harming"
)

HEALING class-attribute instance-attribute

HEALING: Identifier[PotionType] = (
    "minecraft:potion_type:healing"
)

INFESTED class-attribute instance-attribute

INFESTED: Identifier[PotionType] = (
    "minecraft:potion_type:infested"
)

INVISIBILITY class-attribute instance-attribute

INVISIBILITY: Identifier[PotionType] = (
    "minecraft:potion_type:invisibility"
)

LEAPING class-attribute instance-attribute

LEAPING: Identifier[PotionType] = (
    "minecraft:potion_type:leaping"
)

LONG_FIRE_RESISTANCE class-attribute instance-attribute

LONG_FIRE_RESISTANCE: Identifier[PotionType] = (
    "minecraft:potion_type:long_fire_resistance"
)

LONG_INVISIBILITY class-attribute instance-attribute

LONG_INVISIBILITY: Identifier[PotionType] = (
    "minecraft:potion_type:long_invisibility"
)

LONG_LEAPING class-attribute instance-attribute

LONG_LEAPING: Identifier[PotionType] = (
    "minecraft:potion_type:long_leaping"
)

LONG_MUNDANE class-attribute instance-attribute

LONG_MUNDANE: Identifier[PotionType] = (
    "minecraft:potion_type:long_mundane"
)

LONG_NIGHTVISION class-attribute instance-attribute

LONG_NIGHTVISION: Identifier[PotionType] = (
    "minecraft:potion_type:long_nightvision"
)

LONG_POISON class-attribute instance-attribute

LONG_POISON: Identifier[PotionType] = (
    "minecraft:potion_type:long_poison"
)

LONG_REGENERATION class-attribute instance-attribute

LONG_REGENERATION: Identifier[PotionType] = (
    "minecraft:potion_type:long_regeneration"
)

LONG_SLOWNESS class-attribute instance-attribute

LONG_SLOWNESS: Identifier[PotionType] = (
    "minecraft:potion_type:long_slowness"
)

LONG_SLOW_FALLING class-attribute instance-attribute

LONG_SLOW_FALLING: Identifier[PotionType] = (
    "minecraft:potion_type:long_slow_falling"
)

LONG_STRENGTH class-attribute instance-attribute

LONG_STRENGTH: Identifier[PotionType] = (
    "minecraft:potion_type:long_strength"
)

LONG_SWIFTNESS class-attribute instance-attribute

LONG_SWIFTNESS: Identifier[PotionType] = (
    "minecraft:potion_type:long_swiftness"
)

LONG_TURTLE_MASTER class-attribute instance-attribute

LONG_TURTLE_MASTER: Identifier[PotionType] = (
    "minecraft:potion_type:long_turtle_master"
)

LONG_WATER_BREATHING class-attribute instance-attribute

LONG_WATER_BREATHING: Identifier[PotionType] = (
    "minecraft:potion_type:long_water_breathing"
)

LONG_WEAKNESS class-attribute instance-attribute

LONG_WEAKNESS: Identifier[PotionType] = (
    "minecraft:potion_type:long_weakness"
)

MUNDANE class-attribute instance-attribute

MUNDANE: Identifier[PotionType] = (
    "minecraft:potion_type:mundane"
)

NIGHTVISION class-attribute instance-attribute

NIGHTVISION: Identifier[PotionType] = (
    "minecraft:potion_type:nightvision"
)

OOZING class-attribute instance-attribute

OOZING: Identifier[PotionType] = (
    "minecraft:potion_type:oozing"
)

POISON class-attribute instance-attribute

POISON: Identifier[PotionType] = (
    "minecraft:potion_type:poison"
)

REGENERATION class-attribute instance-attribute

REGENERATION: Identifier[PotionType] = (
    "minecraft:potion_type:regeneration"
)

SLOWNESS class-attribute instance-attribute

SLOWNESS: Identifier[PotionType] = (
    "minecraft:potion_type:slowness"
)

SLOW_FALLING class-attribute instance-attribute

SLOW_FALLING: Identifier[PotionType] = (
    "minecraft:potion_type:slow_falling"
)

STRENGTH class-attribute instance-attribute

STRENGTH: Identifier[PotionType] = (
    "minecraft:potion_type:strength"
)

STRONG_HARMING class-attribute instance-attribute

STRONG_HARMING: Identifier[PotionType] = (
    "minecraft:potion_type:strong_harming"
)

STRONG_HEALING class-attribute instance-attribute

STRONG_HEALING: Identifier[PotionType] = (
    "minecraft:potion_type:strong_healing"
)

STRONG_LEAPING class-attribute instance-attribute

STRONG_LEAPING: Identifier[PotionType] = (
    "minecraft:potion_type:strong_leaping"
)

STRONG_POISON class-attribute instance-attribute

STRONG_POISON: Identifier[PotionType] = (
    "minecraft:potion_type:strong_poison"
)

STRONG_REGENERATION class-attribute instance-attribute

STRONG_REGENERATION: Identifier[PotionType] = (
    "minecraft:potion_type:strong_regeneration"
)

STRONG_SLOWNESS class-attribute instance-attribute

STRONG_SLOWNESS: Identifier[PotionType] = (
    "minecraft:potion_type:strong_slowness"
)

STRONG_STRENGTH class-attribute instance-attribute

STRONG_STRENGTH: Identifier[PotionType] = (
    "minecraft:potion_type:strong_strength"
)

STRONG_SWIFTNESS class-attribute instance-attribute

STRONG_SWIFTNESS: Identifier[PotionType] = (
    "minecraft:potion_type:strong_swiftness"
)

STRONG_TURTLE_MASTER class-attribute instance-attribute

STRONG_TURTLE_MASTER: Identifier[PotionType] = (
    "minecraft:potion_type:strong_turtle_master"
)

SWIFTNESS class-attribute instance-attribute

SWIFTNESS: Identifier[PotionType] = (
    "minecraft:potion_type:swiftness"
)

THICK class-attribute instance-attribute

THICK: Identifier[PotionType] = (
    "minecraft:potion_type:thick"
)

TURTLE_MASTER class-attribute instance-attribute

TURTLE_MASTER: Identifier[PotionType] = (
    "minecraft:potion_type:turtle_master"
)

WATER class-attribute instance-attribute

WATER: Identifier[PotionType] = (
    "minecraft:potion_type:water"
)

WATER_BREATHING class-attribute instance-attribute

WATER_BREATHING: Identifier[PotionType] = (
    "minecraft:potion_type:water_breathing"
)

WEAKNESS class-attribute instance-attribute

WEAKNESS: Identifier[PotionType] = (
    "minecraft:potion_type:weakness"
)

WEAVING class-attribute instance-attribute

WEAVING: Identifier[PotionType] = (
    "minecraft:potion_type:weaving"
)

WIND_CHARGED class-attribute instance-attribute

WIND_CHARGED: Identifier[PotionType] = (
    "minecraft:potion_type:wind_charged"
)

WITHER class-attribute instance-attribute

WITHER: Identifier[PotionType] = (
    "minecraft:potion_type:wither"
)

id property

id: Identifier[PotionType]

The identifier of this potion type.

translation_key property

translation_key: str

The translation key, suitable for use in a translation component.

get staticmethod

get(name: Identifier[PotionType] | str) -> PotionType

Attempts to get the PotionType with the given name.

Parameters:

Name Type Description Default
name Identifier[PotionType] | str

The identifier of the potion type (e.g. minecraft:potion_type:water).

required

Returns:

Type Description
PotionType

The PotionType, or None if no potion type with that name exists.