Class EntityEvent

java.lang.Object
org.bukkit.event.Event
org.bukkit.event.entity.EntityEvent
Direct Known Subclasses:
AreaEffectCloudApplyEvent, ArrowBodyCountChangeEvent, BatToggleSleepEvent, CreeperPowerEvent, EnderDragonChangePhaseEvent, EntityAirChangeEvent, EntityBreedEvent, EntityChangeBlockEvent, EntityCombustEvent, EntityCreatePortalEvent, EntityDamageEvent, EntityDeathEvent, EntityDismountEvent, EntityDismountEvent, EntityDropItemEvent, EntityEnterBlockEvent, EntityEnterLoveModeEvent, EntityExhaustionEvent, EntityExplodeEvent, EntityInteractEvent, EntityKnockbackEvent, EntityMountEvent, EntityMountEvent, EntityPickupItemEvent, EntityPlaceEvent, EntityPortalEnterEvent, EntityPoseChangeEvent, EntityPotionEffectEvent, EntityRegainHealthEvent, EntityRemoveEvent, EntityResurrectEvent, EntityShootBowEvent, EntitySpawnEvent, EntitySpellCastEvent, EntityTameEvent, EntityTargetEvent, EntityTeleportEvent, EntityToggleGlideEvent, EntityToggleSwimEvent, EntityTransformEvent, EntityUnleashEvent, ExplosionPrimeEvent, FireworkExplodeEvent, FoodLevelChangeEvent, HorseJumpEvent, ItemDespawnEvent, ItemMergeEvent, PiglinBarterEvent, PigZombieAngerEvent, ProjectileHitEvent, SheepDyeWoolEvent, SheepRegrowWoolEvent, SlimeSplitEvent, StriderTemperatureChangeEvent, VillagerAcquireTradeEvent, VillagerCareerChangeEvent, VillagerReplenishTradeEvent

public abstract class EntityEvent extends Event
Represents an Entity-related event
  • Field Details

    • entity

      protected Entity entity
  • Constructor Details

    • EntityEvent

      public EntityEvent(@NotNull Entity what)
  • Method Details

    • getEntity

      @NotNull public Entity getEntity()
      Returns the Entity involved in this event
      Returns:
      Entity who is involved in this event
    • getEntityType

      @NotNull public EntityType getEntityType()
      Gets the EntityType of the Entity involved in this event.
      Returns:
      EntityType of the Entity involved in this event