Interface KitManager


public interface KitManager
The kit system. Get it from EssentialsCAPI.getKitManager(). If kits are disabled everything just returns empty or false.
  • Method Details

    • getLoadedKits

      Collection<Kit> getLoadedKits()
      Gets all loaded kits.
      Returns:
      loaded kits, never null
    • findKitByName

      Kit findKitByName(String name)
      Finds a kit by name.
      Parameters:
      name - the kit name
      Returns:
      the kit, or null if not found
    • getKitsAvailableTo

      Collection<Kit> getKitsAvailableTo(org.bukkit.entity.Player player)
      Gets the kits a player can claim right now.
      Parameters:
      player - the player
      Returns:
      available kits
    • hasCooldownExpiredFor

      boolean hasCooldownExpiredFor(org.bukkit.entity.Player player, Kit kit)
      Checks if the player's cooldown for a kit is over.
      Parameters:
      player - the player
      kit - the kit
      Returns:
      true if no cooldown left
    • fetchCooldownRemainingAsync

      CompletableFuture<Long> fetchCooldownRemainingAsync(org.bukkit.entity.Player player, Kit kit)
      Gets the remaining cooldown, fetching fresh data.
      Parameters:
      player - the player
      kit - the kit
      Returns:
      future with remaining seconds, 0 if none
    • getRemainingCooldownSeconds

      long getRemainingCooldownSeconds(org.bukkit.entity.Player player, Kit kit)
      Gets the cached remaining cooldown in seconds, 0 if none.
      Parameters:
      player - the player
      kit - the kit
      Returns:
      remaining seconds
    • hasPlayerClaimed

      boolean hasPlayerClaimed(org.bukkit.entity.Player player, Kit kit)
      Checks if the player ever claimed the kit.
      Parameters:
      player - the player
      kit - the kit
      Returns:
      true if claimed before
    • getPlayerClaimCount

      int getPlayerClaimCount(org.bukkit.entity.Player player, Kit kit)
      Gets how many times the player claimed the kit.
      Parameters:
      player - the player
      kit - the kit
      Returns:
      total claims
    • fetchClaimProfile

      KitClaimProfile fetchClaimProfile(org.bukkit.entity.Player player, Kit kit)
      Gets the player's claim history for the kit.
      Parameters:
      player - the player
      kit - the kit
      Returns:
      the claim profile
    • isClaimAllowedFor

      boolean isClaimAllowedFor(org.bukkit.entity.Player player, Kit kit)
      Checks if the player is allowed to claim the kit right now.
      Parameters:
      player - the player
      kit - the kit
      Returns:
      true if allowed
    • isPermittedToUse

      boolean isPermittedToUse(org.bukkit.entity.Player player, Kit kit)
      Checks if the player has the kit permission.
      Parameters:
      player - the player
      kit - the kit
      Returns:
      true if permitted
    • reloadKitDefinitions

      void reloadKitDefinitions()
      Reloads kits from disk.
    • claimKitForPlayer

      CompletableFuture<Void> claimKitForPlayer(org.bukkit.entity.Player player, Kit kit)
      Claims the kit for the player. The future fails if the claim is rejected (permission, cooldown, limits).
      Parameters:
      player - the player
      kit - the kit
      Returns:
      future that completes when the items are given
    • getTotalLoadedKitCount

      int getTotalLoadedKitCount()
      Gets how many kits are loaded.
      Returns:
      loaded kit count
    • isKitLoaded

      boolean isKitLoaded(String name)
      Checks if a kit with this name is loaded.
      Parameters:
      name - the kit name
      Returns:
      true if loaded
    • areItemNamesStrippedOnClaim

      boolean areItemNamesStrippedOnClaim()
      Checks if custom item names are stripped on claim.
      Returns:
      true if stripped