- All Implemented Interfaces:
Called when a splash potion hits an area
Nested Class Summary
Method SummaryModifier and TypeMethodDescriptionRetrieves a list of all effected entitiesReturns the Entity involved in this event
doubleGets the intensity of the potion's effects for given entity; This depends on the distance to the impact centerGets the potion which caused this event
booleanGets the cancellation state of this event.
(boolean cancel)Whether to cancel the action that occurs when the projectile hits.
voidOverwrites the intensity for a given entity
Methods inherited from class org.bukkit.event.entity.ProjectileHitEvent
getHitBlock, getHitBlockFace, getHitEntity
getEntityDescription copied from class:
EntityEventReturns the Entity involved in this event
getPotionGets the potion which caused this event
- The thrown potion entity
getAffectedEntitiesRetrieves a list of all effected entities
- A fresh copy of the affected entity list
getIntensityGets the intensity of the potion's effects for given entity; This depends on the distance to the impact center
entity- Which entity to get intensity for
- intensity relative to maximum effect; 0.0: not affected; 1.0: fully hit by potion effects
setIntensityOverwrites the intensity for a given entity
entity- For which entity to define a new intensity
intensity- relative to maximum effect
isCancelledpublic boolean isCancelled()Description copied from interface:
CancellableGets the cancellation state of this event. A cancelled event will not be executed in the server, but will still pass to other plugins
setCancelledpublic void setCancelled
(boolean cancel)Description copied from class:
ProjectileHitEventWhether to cancel the action that occurs when the projectile hits. In the case of an entity, it will not collide (unless it's a firework, then use
In the case of a block, some blocks (eg target block, bell) will not perform the action associated.
This does NOT prevent block collisions, and explosions will still occur unless their respective events are cancelled.