Package com.plotsquared.core.events
Class PlayerTeleportToPlotEvent
java.lang.Object
com.plotsquared.core.events.PlotEvent
com.plotsquared.core.events.PlotPlayerEvent
com.plotsquared.core.events.PlayerTeleportToPlotEvent
- All Implemented Interfaces:
CancellablePlotEvent
Called when a player teleports to a plot
-
Constructor Summary
ConstructorDescriptionPlayerTeleportToPlotEvent
(PlotPlayer<?> player, Location from, Plot plot) Deprecated, for removal: This API element is subject to removal in a future version.PlayerTeleportToPlotEvent
(PlotPlayer<?> player, Location from, Plot plot, TeleportCause cause) PlayerTeleportToPlotEvent: Called when a player teleports to a plot -
Method Summary
Methods inherited from class com.plotsquared.core.events.PlotPlayerEvent
getPlotPlayer
Methods inherited from class com.plotsquared.core.events.PlotEvent
getEventName, getPlot
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.plotsquared.core.events.CancellablePlotEvent
getEventResultRaw
-
Constructor Details
-
PlayerTeleportToPlotEvent
@Deprecated(forRemoval=true, since="6.1.0") public PlayerTeleportToPlotEvent(PlotPlayer<?> player, Location from, Plot plot) Deprecated, for removal: This API element is subject to removal in a future version.usePlayerTeleportToPlotEvent(PlotPlayer, Location, Plot, TeleportCause)
. You should not be creating events in the first place. -
PlayerTeleportToPlotEvent
public PlayerTeleportToPlotEvent(PlotPlayer<?> player, Location from, Plot plot, TeleportCause cause) PlayerTeleportToPlotEvent: Called when a player teleports to a plot- Parameters:
player
- That was teleportedfrom
- Start locationplot
- Plot to which the player was teleportedcause
- Why the teleport is being completed- Since:
- 6.1.0
-
-
Method Details
-
getCause
Get the teleport cause- Returns:
- TeleportCause
- Since:
- 6.1.0
-
getFrom
Get the from location- Returns:
- Location
-
getEventResult
- Specified by:
getEventResult
in interfaceCancellablePlotEvent
-
setEventResult
- Specified by:
setEventResult
in interfaceCancellablePlotEvent
-
PlayerTeleportToPlotEvent(PlotPlayer, Location, Plot, TeleportCause)
.