Package org.bukkit.event.block
Enum Class TNTPrimeEvent.PrimeCause
- All Implemented Interfaces:
Serializable
,Comparable<TNTPrimeEvent.PrimeCause>
,Constable
- Enclosing class:
- TNTPrimeEvent
An enum to represent the cause of a TNT block becoming primed.
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum ConstantDescriptionWhen TNT with the unstable block state set to true is broken.When TNT is primed by a dispenser holding flint and steel.When TNT is primed by a nearby explosion.When TNT is primed by fire spreading.When TNT is primed by a player interacting with it directly.When TNT is primed after getting hit with a burning projectile.When TNT is primed by a redstone signal. -
Method Summary
Modifier and TypeMethodDescriptionstatic TNTPrimeEvent.PrimeCause
Returns the enum constant of this class with the specified name.static TNTPrimeEvent.PrimeCause[]
values()
Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
FIRE
When TNT is primed by fire spreading. -
REDSTONE
When TNT is primed by a redstone signal. -
PLAYER
When TNT is primed by a player interacting with it directly. -
EXPLOSION
When TNT is primed by a nearby explosion. -
PROJECTILE
When TNT is primed after getting hit with a burning projectile. -
BLOCK_BREAK
When TNT with the unstable block state set to true is broken.Note: Canceling a prime event with this cause will stop the primed TNT from spawning but will not stop the block from being broken.
-
DISPENSER
When TNT is primed by a dispenser holding flint and steel.Note: This event is not called for a dispenser dispensing TNT directly.
-
-
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
-