Class PlayerChangeSectionEvent
java.lang.Object
org.bukkit.event.Event
fr.prodrivers.bukkit.commons.events.PlayerChangeSectionEvent
- All Implemented Interfaces:
org.bukkit.event.Cancellable
public class PlayerChangeSectionEvent
extends org.bukkit.event.Event
implements org.bukkit.event.Cancellable
Event triggered when a player moves from one section to another, before the moving is actually done.
-
Nested Class Summary
Nested classes/interfaces inherited from class org.bukkit.event.Event
org.bukkit.event.Event.Result
-
Method Summary
Modifier and TypeMethodDescriptionstatic org.bukkit.event.HandlerList
Return handlers of this event.@NonNull org.bukkit.event.HandlerList
Get the left section.org.bukkit.entity.Player
Get the player that is moving.Get the target section.boolean
void
setCancelled
(boolean cancelled) Methods inherited from class org.bukkit.event.Event
getEventName, isAsynchronous
-
Method Details
-
getPlayer
public org.bukkit.entity.Player getPlayer()Get the player that is moving.- Returns:
- Player that is moving
-
getLeftSection
Get the left section.- Returns:
- Left section
-
getTargetSection
Get the target section.- Returns:
- Target section
-
isCancelled
public boolean isCancelled()- Specified by:
isCancelled
in interfaceorg.bukkit.event.Cancellable
-
setCancelled
public void setCancelled(boolean cancelled) - Specified by:
setCancelled
in interfaceorg.bukkit.event.Cancellable
-
getHandlers
public @NonNull org.bukkit.event.HandlerList getHandlers()- Specified by:
getHandlers
in classorg.bukkit.event.Event
-
getHandlerList
public static org.bukkit.event.HandlerList getHandlerList()Return handlers of this event. Mandated by Bukkit.- Returns:
- Handler list
-