Package org.bukkit

# Class GameEvent

java.lang.Object
org.bukkit.GameEvent

All Implemented Interfaces:
  `net.kyori.adventure.key.Keyed`, `Keyed`

public final class GameEvent extends Object implements Keyed
Represents a generic Mojang game event.

## Field Summary

Fields
Modifier and Type
Field
Description
`static final GameEvent`
`BLOCK_ACTIVATE`
`static final GameEvent`
`BLOCK_ATTACH`
`static final GameEvent`
`BLOCK_CHANGE`
`static final GameEvent`
`BLOCK_CLOSE`
`static final GameEvent`
`BLOCK_DEACTIVATE`
`static final GameEvent`
`BLOCK_DESTROY`
`static final GameEvent`
`BLOCK_DETACH`
`static final GameEvent`
`BLOCK_OPEN`
`static final GameEvent`
`BLOCK_PLACE`
`static final GameEvent`
`BLOCK_PRESS`
Deprecated.
`static final GameEvent`
`BLOCK_SWITCH`
Deprecated.
`static final GameEvent`
`BLOCK_UNPRESS`
Deprecated.
`static final GameEvent`
`BLOCK_UNSWITCH`
Deprecated.
`static final GameEvent`
`CONTAINER_CLOSE`
`static final GameEvent`
`CONTAINER_OPEN`
`static final GameEvent`
`DISPENSE_FAIL`
`static final GameEvent`
`DRINK`
`static final GameEvent`
`DRINKING_FINISH`
Deprecated.
`static final GameEvent`
`EAT`
`static final GameEvent`
`ELYTRA_FREE_FALL`
Deprecated.
`static final GameEvent`
`ELYTRA_GLIDE`
`static final GameEvent`
`ENTITY_DAMAGE`
`static final GameEvent`
`ENTITY_DAMAGED`
Deprecated.
`static final GameEvent`
`ENTITY_DIE`
`static final GameEvent`
`ENTITY_DYING`
Deprecated.
`static final GameEvent`
`ENTITY_INTERACT`
`static final GameEvent`
`ENTITY_KILLED`
Deprecated.
`static final GameEvent`
`ENTITY_PLACE`
`static final GameEvent`
`ENTITY_ROAR`
`static final GameEvent`
`ENTITY_SHAKE`
`static final GameEvent`
`EQUIP`
`static final GameEvent`
`EXPLODE`
`static final GameEvent`
`FLAP`
`static final GameEvent`
`FLUID_PICKUP`
`static final GameEvent`
`FLUID_PLACE`
`static final GameEvent`
`HIT_GROUND`
`static final GameEvent`
`INSTRUMENT_PLAY`
`static final GameEvent`
`ITEM_INTERACT_FINISH`
`static final GameEvent`
`ITEM_INTERACT_START`
`static final GameEvent`
`JUKEBOX_PLAY`
`static final GameEvent`
`JUKEBOX_STOP_PLAY`
`static final GameEvent`
`LIGHTNING_STRIKE`
`static final GameEvent`
`MOB_INTERACT`
Deprecated.
`static final GameEvent`
`NOTE_BLOCK_PLAY`
`static final GameEvent`
`PISTON_CONTRACT`
`static final GameEvent`
`PISTON_EXTEND`
`static final GameEvent`
`PRIME_FUSE`
`static final GameEvent`
`PROJECTILE_LAND`
`static final GameEvent`
`PROJECTILE_SHOOT`
`static final GameEvent`
`RAVAGER_ROAR`
Deprecated.
`static final GameEvent`
`RING_BELL`
Deprecated.
`static final GameEvent`
`SCULK_SENSOR_TENDRILS_CLICKING`
`static final GameEvent`
`SHEAR`
`static final GameEvent`
`SHRIEK`
`static final GameEvent`
`SHULKER_CLOSE`
Deprecated.
`static final GameEvent`
`SHULKER_OPEN`
Deprecated.
`static final GameEvent`
`SPLASH`
`static final GameEvent`
`STEP`
`static final GameEvent`
`SWIM`
`static final GameEvent`
`TELEPORT`
`static final GameEvent`
`WOLF_SHAKING`
Deprecated.

## Method Summary

Modifier and Type
Method
Description
`static @Nullable GameEvent`
`getByKey(@NotNull NamespacedKey namespacedKey)`
Returns a `GameEvent` by a `NamespacedKey`.
`@NotNull NamespacedKey`
`getKey()`
Return the namespaced identifier for this object.
`static @NotNull Collection<GameEvent>`
`values()`
Returns the set of all GameEvents.

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Methods inherited from interface org.bukkit.Keyed

`key`

## Field Details

### BLOCK_ACTIVATE

public static final GameEvent BLOCK_ACTIVATE

### BLOCK_ATTACH

public static final GameEvent BLOCK_ATTACH

### BLOCK_CHANGE

public static final GameEvent BLOCK_CHANGE

### BLOCK_CLOSE

public static final GameEvent BLOCK_CLOSE

### BLOCK_DEACTIVATE

public static final GameEvent BLOCK_DEACTIVATE

### BLOCK_DESTROY

public static final GameEvent BLOCK_DESTROY

### BLOCK_DETACH

public static final GameEvent BLOCK_DETACH

### BLOCK_OPEN

public static final GameEvent BLOCK_OPEN

### BLOCK_PLACE

public static final GameEvent BLOCK_PLACE

### BLOCK_PRESS

@Deprecated public static final GameEvent BLOCK_PRESS
Deprecated.

### BLOCK_SWITCH

@Deprecated public static final GameEvent BLOCK_SWITCH
Deprecated.

### BLOCK_UNPRESS

@Deprecated public static final GameEvent BLOCK_UNPRESS
Deprecated.

### BLOCK_UNSWITCH

@Deprecated public static final GameEvent BLOCK_UNSWITCH
Deprecated.

### CONTAINER_CLOSE

public static final GameEvent CONTAINER_CLOSE

### CONTAINER_OPEN

public static final GameEvent CONTAINER_OPEN

### DISPENSE_FAIL

public static final GameEvent DISPENSE_FAIL

### DRINK

public static final GameEvent DRINK

### DRINKING_FINISH

@Deprecated public static final GameEvent DRINKING_FINISH
Deprecated.

### EAT

public static final GameEvent EAT

### ELYTRA_FREE_FALL

@Deprecated public static final GameEvent ELYTRA_FREE_FALL
Deprecated.

### ELYTRA_GLIDE

public static final GameEvent ELYTRA_GLIDE

### ENTITY_DAMAGE

public static final GameEvent ENTITY_DAMAGE

### ENTITY_DAMAGED

@Deprecated public static final GameEvent ENTITY_DAMAGED
Deprecated.

### ENTITY_DIE

public static final GameEvent ENTITY_DIE

### ENTITY_DYING

@Deprecated public static final GameEvent ENTITY_DYING
Deprecated.

### ENTITY_INTERACT

public static final GameEvent ENTITY_INTERACT

### ENTITY_KILLED

@Deprecated public static final GameEvent ENTITY_KILLED
Deprecated.

### ENTITY_PLACE

public static final GameEvent ENTITY_PLACE

### ENTITY_ROAR

public static final GameEvent ENTITY_ROAR

### ENTITY_SHAKE

public static final GameEvent ENTITY_SHAKE

### EQUIP

public static final GameEvent EQUIP

### EXPLODE

public static final GameEvent EXPLODE

### FLAP

public static final GameEvent FLAP

### FLUID_PICKUP

public static final GameEvent FLUID_PICKUP

### FLUID_PLACE

public static final GameEvent FLUID_PLACE

### HIT_GROUND

public static final GameEvent HIT_GROUND

### INSTRUMENT_PLAY

public static final GameEvent INSTRUMENT_PLAY

### ITEM_INTERACT_FINISH

public static final GameEvent ITEM_INTERACT_FINISH

### ITEM_INTERACT_START

public static final GameEvent ITEM_INTERACT_START

### JUKEBOX_PLAY

public static final GameEvent JUKEBOX_PLAY

### JUKEBOX_STOP_PLAY

public static final GameEvent JUKEBOX_STOP_PLAY

### LIGHTNING_STRIKE

public static final GameEvent LIGHTNING_STRIKE

### MOB_INTERACT

@Deprecated public static final GameEvent MOB_INTERACT
Deprecated.

### NOTE_BLOCK_PLAY

public static final GameEvent NOTE_BLOCK_PLAY

### PISTON_CONTRACT

public static final GameEvent PISTON_CONTRACT

### PISTON_EXTEND

public static final GameEvent PISTON_EXTEND

### PRIME_FUSE

public static final GameEvent PRIME_FUSE

### PROJECTILE_LAND

public static final GameEvent PROJECTILE_LAND

### PROJECTILE_SHOOT

public static final GameEvent PROJECTILE_SHOOT

### RAVAGER_ROAR

@Deprecated public static final GameEvent RAVAGER_ROAR
Deprecated.

### RING_BELL

@Deprecated public static final GameEvent RING_BELL
Deprecated.

### SCULK_SENSOR_TENDRILS_CLICKING

public static final GameEvent SCULK_SENSOR_TENDRILS_CLICKING

### SHEAR

public static final GameEvent SHEAR

### SHRIEK

public static final GameEvent SHRIEK

### SHULKER_CLOSE

@Deprecated public static final GameEvent SHULKER_CLOSE
Deprecated.

### SHULKER_OPEN

@Deprecated public static final GameEvent SHULKER_OPEN
Deprecated.

### SPLASH

public static final GameEvent SPLASH

### STEP

public static final GameEvent STEP

### SWIM

public static final GameEvent SWIM

### TELEPORT

public static final GameEvent TELEPORT

### WOLF_SHAKING

@Deprecated public static final GameEvent WOLF_SHAKING
Deprecated.

## Method Details

### getKey

@NotNull public @NotNull NamespacedKey getKey()
Description copied from interface: `Keyed`
Return the namespaced identifier for this object.

Specified by:
  `getKey` in interface `Keyed`
Returns:
  this object's key

### getByKey

@Nullable public static @Nullable GameEvent getByKey(@NotNull @NotNull NamespacedKey namespacedKey)
Returns a `GameEvent` by a `NamespacedKey`.

Parameters:
  `namespacedKey` - the key
Returns:
  the event or null

### values

@NotNull public static @NotNull Collection<GameEvent> values()
Returns the set of all GameEvents.

Returns:
  the memoryKeys