Class AbstractTeleporter
This abstraction allows for direct teleportation of players using NMS methods, bypassing the standard Bukkit teleportation system which fires events and performs additional checks. This can be useful for internal teleportation operations where events should not be triggered.
Warning: Using this class bypasses Bukkit's teleportation events and safety checks. Ensure that any necessary validation is performed manually when using these methods.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionabstract void
teleportWithoutEvent
(Player player, Location location) Teleports a player to the specified location without triggering Bukkit events.
-
Constructor Details
-
AbstractTeleporter
public AbstractTeleporter()
-
-
Method Details
-
teleportWithoutEvent
Teleports a player to the specified location without triggering Bukkit events.This method performs a direct teleportation using NMS methods, completely bypassing Bukkit's event system. No
PlayerTeleportEvent
will be fired, and no plugins will be notified of the teleportation.This is useful for internal operations where you need to move a player without other plugins interfering or being notified of the movement.
-