Package io.papermc.paper.event.entity
Class EntityPortalReadyEvent
java.lang.Object
org.bukkit.event.Event
org.bukkit.event.entity.EntityEvent
io.papermc.paper.event.entity.EntityPortalReadyEvent
- All Implemented Interfaces:
- Cancellable
Called when an entity is ready to be teleported by a plugin.
 Currently this is only called after the required
 ticks have passed for a Nether Portal.
 
Cancelling this event resets the entity's readiness regarding the current portal.
- 
Nested Class SummaryNested classes/interfaces inherited from class org.bukkit.event.EventEvent.Result
- 
Field SummaryFields inherited from class org.bukkit.event.entity.EntityEvententity
- 
Constructor SummaryConstructorsConstructorDescriptionEntityPortalReadyEvent(@NotNull Entity entity, @Nullable World targetWorld, @NotNull PortalType portalType) 
- 
Method SummaryModifier and TypeMethodDescriptionstatic @NotNull HandlerListGets the portal type for this event.Gets the world this portal will teleport to.booleanGets the cancellation state of this event.voidsetCancelled(boolean cancel) Sets the cancellation state of this event.voidsetTargetWorld(@Nullable World targetWorld) Sets the world this portal will teleport to.Methods inherited from class org.bukkit.event.entity.EntityEventgetEntity, getEntityTypeMethods inherited from class org.bukkit.event.EventcallEvent, getEventName, isAsynchronous
- 
Constructor Details- 
EntityPortalReadyEvent
 
- 
- 
Method Details- 
getTargetWorldGets the world this portal will teleport to. Can be null if "allow-nether" is false in server.properties or if there is another situation where there is no world to teleport to.This world may be modified by later events such as PlayerPortalEventorEntityPortalEvent.- Returns:
- the world the portal will teleport the entity to.
 
- 
setTargetWorldSets the world this portal will teleport to. A null value will essentially cancel the teleport and prevent further events such asPlayerPortalEventfrom firing.This world may be modified by later events such as PlayerPortalEventorEntityPortalEvent.- Parameters:
- targetWorld- the world
 
- 
getPortalTypeGets the portal type for this event.- Returns:
- the portal type
 
- 
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- Specified by:
- isCancelledin interface- Cancellable
- Returns:
- true if this event is cancelled
 
- 
setCancelledpublic void setCancelled(boolean cancel) Description copied from interface:CancellableSets the cancellation state of this event. A cancelled event will not be executed in the server, but will still pass to other plugins.- Specified by:
- setCancelledin interface- Cancellable
- Parameters:
- cancel- true if you wish to cancel this event
 
- 
getHandlers- Specified by:
- getHandlersin class- Event
 
- 
getHandlerList
 
-