Class MoveEventListener
java.lang.Object
org.sgrewritten.stargate.listener.MoveEventListener
- All Implemented Interfaces:
org.bukkit.event.Listener
A listener for relevant move events, such as a player entering a stargate
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
onEntityPortalTeleport
(@NotNull org.bukkit.event.entity.EntityPortalEvent event) Listens for and cancels any default vehicle portal events caused by stargatesvoid
onPlayerMove
(@NotNull org.bukkit.event.player.PlayerMoveEvent event) Listens for any player movement and teleports the player if entering a stargatevoid
onPlayerTeleport
(@NotNull org.bukkit.event.player.PlayerTeleportEvent event) Listens for and cancels any default player teleportation events caused by stargatesvoid
onVehicleMove
(org.bukkit.event.vehicle.VehicleMoveEvent event) Listens for any vehicle movement and teleports the vehicle if entering a stargate
-
Constructor Details
-
MoveEventListener
- Parameters:
registry
-the registry containing all information about portals
-
-
Method Details
-
onEntityPortalTeleport
public void onEntityPortalTeleport(@NotNull @NotNull org.bukkit.event.entity.EntityPortalEvent event) Listens for and cancels any default vehicle portal events caused by stargates- Parameters:
event
-The triggered entity portal event
-
onPlayerTeleport
public void onPlayerTeleport(@NotNull @NotNull org.bukkit.event.player.PlayerTeleportEvent event) Listens for and cancels any default player teleportation events caused by stargates- Parameters:
event
-The triggered player teleportation event
-
onPlayerMove
public void onPlayerMove(@NotNull @NotNull org.bukkit.event.player.PlayerMoveEvent event) Listens for any player movement and teleports the player if entering a stargate- Parameters:
event
-The triggered player move event
-
onVehicleMove
public void onVehicleMove(org.bukkit.event.vehicle.VehicleMoveEvent event) Listens for any vehicle movement and teleports the vehicle if entering a stargate- Parameters:
event
-The triggered vehicle move event
-