Class SkillTree

java.lang.Object
studio.magemonkey.fabled.tree.SkillTree
Direct Known Subclasses:
InventoryTree

public abstract class SkillTree extends Object
Represents a skill tree that contains an arrangement of a class's skills for a player to browse and level up or refund skills.
  • Field Details

  • Constructor Details

    • SkillTree

      public SkillTree(Fabled api, FabledClass tree)
      Constructor
      Parameters:
      api - api reference
  • Method Details

    • canShow

      public boolean canShow(org.bukkit.entity.Player player, Skill skill)
      Checks whether the player can be shown the skill
      Parameters:
      player - player to check for
      skill - skill to check for permissions
      Returns:
      true if skill can be shown, false otherwise
    • arrange

      public void arrange() throws SkillTreeException
      Arranges the skill tree
      Throws:
      SkillTreeException
    • arrange

      protected abstract void arrange(List<Skill> skills) throws SkillTreeException
      Arranges the skill tree
      Parameters:
      skills - skills to arrange
      Throws:
      SkillTreeException
    • hasSkill

      public abstract boolean hasSkill(Skill skill)
      Checks if the class has the skill registered
      Parameters:
      skill - skill to check
      Returns:
      true if registered, false otherwise