Package cn.nukkit.event.entity
Enum Class EntityDamageEvent.DamageCause
- All Implemented Interfaces:
Serializable
,Comparable<EntityDamageEvent.DamageCause>
,Constable
- Enclosing class:
- EntityDamageEvent
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum ConstantDescriptionBlock explosion damageDamage caused by a lot of (>24) entities colliding togetherDamage caused by contact with a block such as a CactusPluginsDamage caused by running out of air underwaterDamage caused by being attacked by another entityEntity explosion damageFall damageDamage caused by falling blockDamage caused by standing in fireBurn damageDamage caused by fireworksDamage caused by flying into wallDamage caused by temperatureDamage caused when an entity steps on a hot block, likeBlockID.MAGMA
Damage caused by hungerDamage caused by standing in lavaDamage caused by being struck by lightningPotion or spell damageDamage caused by no reason (eg: /damage command with cause NONE)Damage caused by being hit by a projectile such as an ArrowDamage caused by being put in a blockPlayer commits suicideDamage caused by thornsDamage caused by falling into the voidDamage caused by Wither -
Method Summary
Modifier and TypeMethodDescriptionReturns the enum constant of this class with the specified name.static EntityDamageEvent.DamageCause[]
values()
Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
CONTACT
Damage caused by contact with a block such as a Cactus -
ENTITY_ATTACK
Damage caused by being attacked by another entity -
PROJECTILE
Damage caused by being hit by a projectile such as an Arrow -
SUFFOCATION
Damage caused by being put in a block -
FALL
Fall damage -
FIRE
Damage caused by standing in fire -
FIRE_TICK
Burn damage -
LAVA
Damage caused by standing in lava -
DROWNING
Damage caused by running out of air underwater -
BLOCK_EXPLOSION
Block explosion damage -
ENTITY_EXPLOSION
Entity explosion damage -
VOID
Damage caused by falling into the void -
SUICIDE
Player commits suicide -
MAGIC
Potion or spell damage -
CUSTOM
Plugins -
LIGHTNING
Damage caused by being struck by lightning -
HUNGER
Damage caused by hunger -
WITHER
Damage caused by Wither -
THORNS
Damage caused by thorns -
FALLING_BLOCK
@PowerNukkitOnly @Since("1.5.2.0-PN") public static final EntityDamageEvent.DamageCause FALLING_BLOCKDamage caused by falling block -
FLYING_INTO_WALL
@PowerNukkitOnly @Since("1.5.2.0-PN") public static final EntityDamageEvent.DamageCause FLYING_INTO_WALLDamage caused by flying into wall -
HOT_FLOOR
Damage caused when an entity steps on a hot block, likeBlockID.MAGMA
-
FIREWORKS
Damage caused by fireworks -
FREEZING
Damage caused by temperature -
NONE
Damage caused by no reason (eg: /damage command with cause NONE) -
COLLIDE
Damage caused by a lot of (>24) entities colliding together
-
-
Method Details
-
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
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 nameNullPointerException
- if the argument is null
-