Klasse HomeTeleportGuard

java.lang.Object
de.delinkedde.areashopreborn.integration.HomeTeleportGuard
Alle implementierten Schnittstellen:
org.bukkit.event.Listener

public final class HomeTeleportGuard extends Object implements org.bukkit.event.Listener
Restricts only teleports preceded by configured CMI/Essentials-style home commands.
  • Konstruktorübersicht

    Konstruktoren
    Konstruktor
    Beschreibung
    HomeTeleportGuard(HomeProtectionCache cache, MessageService messages, List<String> commands, Duration intentTimeout, boolean enabled)
    Creates the optional home teleport guard.
  • Methodenübersicht

    Modifizierer und Typ
    Methode
    Beschreibung
    void
    onCommand(org.bukkit.event.player.PlayerCommandPreprocessEvent event)
    Records a successful command preprocess event without attempting to resolve its destination.
    void
    onQuit(org.bukkit.event.player.PlayerQuitEvent event)
    Removes an abandoned home intent when a player disconnects.
    void
    onTeleport(org.bukkit.event.player.PlayerTeleportEvent event)
    Applies the cached policy to the next command/plugin teleport belonging to a home intent.

    Von Klasse geerbte Methoden java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Konstruktordetails

    • HomeTeleportGuard

      public HomeTeleportGuard(HomeProtectionCache cache, MessageService messages, List<String> commands, Duration intentTimeout, boolean enabled)
      Creates the optional home teleport guard.
      Parameter:
      cache - non-blocking authorization cache
      messages - configurable message renderer
      commands - normalized command prefixes identifying home requests
      intentTimeout - maximum delay between command and teleport
      enabled - whether a supported provider and feature configuration are active
  • Methodendetails

    • onCommand

      public void onCommand(org.bukkit.event.player.PlayerCommandPreprocessEvent event)
      Records a successful command preprocess event without attempting to resolve its destination.
      Parameter:
      event - player command event
    • onTeleport

      public void onTeleport(org.bukkit.event.player.PlayerTeleportEvent event)
      Applies the cached policy to the next command/plugin teleport belonging to a home intent.
      Parameter:
      event - player teleport event
    • onQuit

      public void onQuit(org.bukkit.event.player.PlayerQuitEvent event)
      Removes an abandoned home intent when a player disconnects.
      Parameter:
      event - player disconnect event