Class AutoClaimSession

java.lang.Object
me.tayebyassine.homestead.sessions.AutoClaimSession

public final class AutoClaimSession extends Object
Tracks which players are in auto-claim mode.

When a player has an active session, every chunk they enter is automatically claimed for their target region.

  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final HashSet<UUID>
     
  • Method Summary

    Modifier and Type
    Method
    Description
    static boolean
    hasSession(org.bukkit.entity.Player player)
    Check whether the given player is in auto-claim mode.
    static void
    newSession(org.bukkit.entity.Player player)
    Enable auto-claim mode for the given player.
    static void
    removeSession(org.bukkit.entity.Player player)
    Disable auto-claim mode for the given player.

    Methods inherited from class Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • SESSIONS

      public static final HashSet<UUID> SESSIONS
  • Method Details

    • newSession

      public static void newSession(org.bukkit.entity.Player player)
      Enable auto-claim mode for the given player.
      Parameters:
      player - the player to enable auto-claim for
    • hasSession

      public static boolean hasSession(org.bukkit.entity.Player player)
      Check whether the given player is in auto-claim mode.
      Parameters:
      player - the player to check
      Returns:
      true if the player has an active auto-claim session
    • removeSession

      public static void removeSession(org.bukkit.entity.Player player)
      Disable auto-claim mode for the given player.
      Parameters:
      player - the player to disable auto-claim for