Package org.bukkit

Enum Class EntityEffect

java.lang.Object
java.lang.Enum<EntityEffect>
org.bukkit.EntityEffect
All Implemented Interfaces:
Serializable, Comparable<EntityEffect>, Constable

public enum EntityEffect extends Enum<EntityEffect>
A list of all effects that can happen to entities.
  • Enum Constant Details

    • ARROW_PARTICLES

      public static final EntityEffect ARROW_PARTICLES
      Colored particles from an arrow.
    • RABBIT_JUMP

      public static final EntityEffect RABBIT_JUMP
      Rabbit jumping.
    • RESET_SPAWNER_MINECART_DELAY

      public static final EntityEffect RESET_SPAWNER_MINECART_DELAY
      Resets a spawner minecart's delay to 200. Does not affect actual spawning delay, only the speed at which the entity in the spawner spins.
    • HURT

      @Deprecated(since="1.20.1", forRemoval=true) public static final EntityEffect HURT
      Deprecated, for removal: This API element is subject to removal in a future version.
      When mobs get hurt.
    • DEATH

      @Deprecated(since="1.12.2", forRemoval=true) public static final EntityEffect DEATH
      Deprecated, for removal: This API element is subject to removal in a future version.
      split into individual effects
      When a mob dies.

      This will cause client-glitches!

      See Also:
    • EGG_BREAK

      @Deprecated(since="1.21.4", forRemoval=true) public static final EntityEffect EGG_BREAK
      Deprecated, for removal: This API element is subject to removal in a future version.
      Spawns the egg breaking particles.
    • SNOWBALL_BREAK

      @Deprecated(since="1.21.4", forRemoval=true) public static final EntityEffect SNOWBALL_BREAK
      Deprecated, for removal: This API element is subject to removal in a future version.
      Spawns the snowball breaking particles.
    • PROJECTILE_CRACK

      public static final EntityEffect PROJECTILE_CRACK
      Shows the crack particles when a projectile hits something.
    • ENTITY_DEATH

      public static final EntityEffect ENTITY_DEATH
      Plays the entity death sound and animation.

      This will cause client-glitches!

    • FANG_ATTACK

      @Deprecated(since="1.21.4", forRemoval=true) public static final EntityEffect FANG_ATTACK
      Deprecated, for removal: This API element is subject to removal in a future version.
      Plays the evoker's fang attack animation.
    • HOGLIN_ATTACK

      @Deprecated(since="1.21.4", forRemoval=true) public static final EntityEffect HOGLIN_ATTACK
      Deprecated, for removal: This API element is subject to removal in a future version.
      Plays the hoglin attack animation.
    • IRON_GOLEN_ATTACK

      @Deprecated(since="1.21.4", forRemoval=true) public static final EntityEffect IRON_GOLEN_ATTACK
      Deprecated, for removal: This API element is subject to removal in a future version.
      Plays the iron golem attack animation.
    • RAVAGER_ATTACK

      @Deprecated(since="1.21.4", forRemoval=true) public static final EntityEffect RAVAGER_ATTACK
      Deprecated, for removal: This API element is subject to removal in a future version.
      Plays the ravager attack animation.
    • WARDEN_ATTACK

      @Deprecated(since="1.21.4", forRemoval=true) public static final EntityEffect WARDEN_ATTACK
      Deprecated, for removal: This API element is subject to removal in a future version.
      Plays the warden attack animation.
    • ZOGLIN_ATTACK

      @Deprecated(since="1.21.4", forRemoval=true) public static final EntityEffect ZOGLIN_ATTACK
      Deprecated, for removal: This API element is subject to removal in a future version.
      Plays the zoglin attack animation.
    • ENTITY_ATTACK

      public static final EntityEffect ENTITY_ATTACK
      Plays an attack animation for the respective entities.
    • WOLF_SMOKE

      @Deprecated(since="1.21", forRemoval=true) public static final EntityEffect WOLF_SMOKE
      Deprecated, for removal: This API element is subject to removal in a future version.
      The smoke when taming an entity fails.
    • WOLF_HEARTS

      @Deprecated(since="1.21", forRemoval=true) public static final EntityEffect WOLF_HEARTS
      Deprecated, for removal: This API element is subject to removal in a future version.
      The hearts when taming an entity succeeds.
    • TAMING_FAILED

      public static final EntityEffect TAMING_FAILED
      The smoke when taming an entity fails.
    • TAMING_SUCCEEDED

      public static final EntityEffect TAMING_SUCCEEDED
      The hearts when taming an entity succeeds.
    • WOLF_SHAKE

      public static final EntityEffect WOLF_SHAKE
      When a wolf shakes (after being wet).
      See Also:
    • SHEEP_EAT

      @Deprecated(since="1.12.2", forRemoval=true) public static final EntityEffect SHEEP_EAT
      Deprecated, for removal: This API element is subject to removal in a future version.
      split into individual effects
      When an entity eats a LONG_GRASS block.
      See Also:
    • SHEEP_EAT_GRASS

      public static final EntityEffect SHEEP_EAT_GRASS
      Plays the sheep eating grass animation.
    • TNT_MINECART_IGNITE

      public static final EntityEffect TNT_MINECART_IGNITE
      Causes the TNT minecart to ignite, does not play the ignition sound

      This will cause client-glitches!

    • IRON_GOLEM_ROSE

      public static final EntityEffect IRON_GOLEM_ROSE
      When an Iron Golem gives a rose.
    • VILLAGER_HEART

      public static final EntityEffect VILLAGER_HEART
      Hearts from a villager.
    • VILLAGER_ANGRY

      public static final EntityEffect VILLAGER_ANGRY
      When a villager is angry.
    • VILLAGER_HAPPY

      public static final EntityEffect VILLAGER_HAPPY
      Happy particles from a villager.
    • WITCH_MAGIC

      public static final EntityEffect WITCH_MAGIC
      Magic particles from a witch.
    • ZOMBIE_TRANSFORM

      public static final EntityEffect ZOMBIE_TRANSFORM
      Plays the sound when a zombie villager is cured.
    • FIREWORK_EXPLODE

      public static final EntityEffect FIREWORK_EXPLODE
      When a firework explodes.
    • LOVE_HEARTS

      public static final EntityEffect LOVE_HEARTS
      Hearts from a breeding entity or when an Allay duplicates.
    • SQUID_ROTATE

      public static final EntityEffect SQUID_ROTATE
      Resets squid rotation.
    • ENTITY_POOF

      public static final EntityEffect ENTITY_POOF
      Silverfish entering block, spawner spawning.
    • GUARDIAN_TARGET

      public static final EntityEffect GUARDIAN_TARGET
      Guardian plays the attack sound effect.
    • SHIELD_BLOCK

      public static final EntityEffect SHIELD_BLOCK
      Shield blocks attack.
    • SHIELD_BREAK

      public static final EntityEffect SHIELD_BREAK
      Shield breaks.
    • ARMOR_STAND_HIT

      public static final EntityEffect ARMOR_STAND_HIT
      Armor stand is hit.
    • THORNS_HURT

      @Deprecated(since="1.19.4", forRemoval=true) public static final EntityEffect THORNS_HURT
      Deprecated, for removal: This API element is subject to removal in a future version.
      Entity hurt by thorns attack.
    • IRON_GOLEM_SHEATH

      public static final EntityEffect IRON_GOLEM_SHEATH
      Iron golem puts away rose.
    • TOTEM_RESURRECT

      @Deprecated(since="1.21.2", forRemoval=true) public static final EntityEffect TOTEM_RESURRECT
      Deprecated, for removal: This API element is subject to removal in a future version.
      Totem prevents entity death.
    • PROTECTED_FROM_DEATH

      public static final EntityEffect PROTECTED_FROM_DEATH
      Item with DataComponentTypes.DEATH_PROTECTION prevents entity death. For player, the item selected will be shown for a moment on the screen, if the item is not found a totem will appear.
    • HURT_DROWN

      @Deprecated(since="1.19.4", forRemoval=true) public static final EntityEffect HURT_DROWN
      Deprecated, for removal: This API element is subject to removal in a future version.
      Entity hurt due to drowning damage.
    • HURT_EXPLOSION

      @Deprecated(since="1.19.4", forRemoval=true) public static final EntityEffect HURT_EXPLOSION
      Deprecated, for removal: This API element is subject to removal in a future version.
      Entity hurt due to explosion damage.
    • DOLPHIN_FED

      public static final EntityEffect DOLPHIN_FED
      Dolphin has been fed and is locating a structure.
    • RAVAGER_STUNNED

      public static final EntityEffect RAVAGER_STUNNED
      Ravager has been stunned for 40 ticks.
    • CAT_TAME_FAIL

      @Deprecated(since="1.14", forRemoval=true) public static final EntityEffect CAT_TAME_FAIL
      Deprecated, for removal: This API element is subject to removal in a future version.
      Cat taming failed.
    • CAT_TAME_SUCCESS

      @Deprecated(since="1.14", forRemoval=true) public static final EntityEffect CAT_TAME_SUCCESS
      Deprecated, for removal: This API element is subject to removal in a future version.
      Cat taming succeeded.
    • TRUSTING_FAILED

      public static final EntityEffect TRUSTING_FAILED
      Ocelot trusting failed.
    • TRUSTING_SUCCEEDED

      public static final EntityEffect TRUSTING_SUCCEEDED
      Ocelot trusting succeeded.
    • VILLAGER_SPLASH

      public static final EntityEffect VILLAGER_SPLASH
      Villager splashes particles during a raid.
    • PLAYER_BAD_OMEN_RAID

      @Deprecated(since="1.20.5", forRemoval=true) public static final EntityEffect PLAYER_BAD_OMEN_RAID
      Deprecated, for removal: This API element is subject to removal in a future version.
      raid system was overhauled in 1.20.5
      Player's bad omen effect removed to start or increase raid difficult.
    • HURT_BERRY_BUSH

      @Deprecated(since="1.19.4", forRemoval=true) public static final EntityEffect HURT_BERRY_BUSH
      Deprecated, for removal: This API element is subject to removal in a future version.
      Entity hurt due to berry bush. Prickly!
    • FOX_CHEW

      public static final EntityEffect FOX_CHEW
      Fox chews the food in its mouth.
    • TELEPORT_ENDER

      public static final EntityEffect TELEPORT_ENDER
      Entity teleported as a result of chorus fruit or as an enderman.
    • BREAK_EQUIPMENT_MAIN_HAND

      public static final EntityEffect BREAK_EQUIPMENT_MAIN_HAND
      Entity breaks item in main hand.
      See Also:
    • BREAK_EQUIPMENT_OFF_HAND

      public static final EntityEffect BREAK_EQUIPMENT_OFF_HAND
      Entity breaks item in off hand.
      See Also:
    • BREAK_EQUIPMENT_HELMET

      public static final EntityEffect BREAK_EQUIPMENT_HELMET
      Entity breaks item in helmet slot.
      See Also:
    • BREAK_EQUIPMENT_CHESTPLATE

      public static final EntityEffect BREAK_EQUIPMENT_CHESTPLATE
      Entity breaks item in chestplate slot.
      See Also:
    • BREAK_EQUIPMENT_LEGGINGS

      public static final EntityEffect BREAK_EQUIPMENT_LEGGINGS
      Entity breaks item in legging slot.
      See Also:
    • BREAK_EQUIPMENT_BOOTS

      public static final EntityEffect BREAK_EQUIPMENT_BOOTS
      Entity breaks item in boot slot.
      See Also:
    • HONEY_BLOCK_SLIDE_PARTICLES

      public static final EntityEffect HONEY_BLOCK_SLIDE_PARTICLES
      Spawns honey block slide particles at the entity's feet.
    • HONEY_BLOCK_FALL_PARTICLES

      public static final EntityEffect HONEY_BLOCK_FALL_PARTICLES
      Spawns honey block fall particles at the entity's feet.
    • SWAP_HAND_ITEMS

      public static final EntityEffect SWAP_HAND_ITEMS
      Entity swaps the items in their hand and offhand
    • WOLF_SHAKE_STOP

      public static final EntityEffect WOLF_SHAKE_STOP
      Stops a wolf that is currently shaking.
      See Also:
    • GOAT_LOWER_HEAD

      public static final EntityEffect GOAT_LOWER_HEAD
      Goat lowers its head for ramming.
      See Also:
    • GOAT_RAISE_HEAD

      public static final EntityEffect GOAT_RAISE_HEAD
      Goat raises its head.
      See Also:
    • SPAWN_DEATH_SMOKE

      public static final EntityEffect SPAWN_DEATH_SMOKE
      Spawns death smoke particles.
    • WARDEN_TENDRIL_SHAKE

      public static final EntityEffect WARDEN_TENDRIL_SHAKE
      Warden shakes its tendrils.
    • WARDEN_SONIC_ATTACK

      public static final EntityEffect WARDEN_SONIC_ATTACK
      Warden performs sonic attack animation.
      Does not play the sound or fire the beam.
    • SNIFFER_DIG

      public static final EntityEffect SNIFFER_DIG
      Plays sniffer digging sound.
      Sniffer must have a target and be in Sniffer.State.SEARCHING or Sniffer.State.DIGGING.
    • ARMADILLO_PEEK

      public static final EntityEffect ARMADILLO_PEEK
      Armadillo peeks out of its shell
    • BODY_BREAK

      @Deprecated(since="1.21.4", forRemoval=true) public static final EntityEffect BODY_BREAK
      Deprecated, for removal: This API element is subject to removal in a future version.
      EquipmentSlot.BODY armor piece breaks.
    • BREAK_EQUIPMENT_BODY

      public static final EntityEffect BREAK_EQUIPMENT_BODY
      Entity breaks item in body slot.
      See Also:
    • SHAKE

      public static final EntityEffect SHAKE
      A creaking transient shaking when being hit. Does not apply to plain creaking entities as they are not invulnerable like the transient ones spawned by the creaking heart.
  • Method Details

    • values

      public static EntityEffect[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static EntityEffect valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (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 class has no constant with the specified name
      NullPointerException - if the argument is null
    • getData

      @Internal public byte getData()
      Gets the data value of this entity effect, may not be unique.
      Returns:
      the data value
    • getApplicable

      @NotNull @Deprecated(since="1.21.4") public @NotNull Class<? extends Entity> getApplicable()
      Deprecated.
      an entity effect can apply to multiple superclasses, see getApplicableClasses()
      Gets entity superclass which this entity effect is applicable to.
      Returns:
      applicable class
    • getApplicableClasses

      @NotNull public @NotNull Set<Class<? extends Entity>> getApplicableClasses()
      Gets the entity superclasses which this entity effect is applicable to.
      Returns:
      the applicable classes
    • isApplicableTo

      public boolean isApplicableTo(@NotNull @NotNull Entity entity)
      Checks if this entity effect is applicable to the given entity.
      Parameters:
      entity - the entity to check
      Returns:
      true if applicable
    • isApplicableTo

      public boolean isApplicableTo(@NotNull @NotNull Class<? extends Entity> clazz)
      Checks if this entity effect is applicable to the given entity class.
      Parameters:
      clazz - the entity class to check
      Returns:
      true if applicable