java.lang.Object
studio.magemonkey.codex.manager.LoadableItem
studio.magemonkey.divinity.modules.list.drops.object.DropTable
All Implemented Interfaces:
DropCalculator

public class DropTable extends studio.magemonkey.codex.manager.LoadableItem implements DropCalculator
  • Field Details

    • name

      protected String name
    • rollOnce

      protected boolean rollOnce
    • worldsGood

      protected Set<String> worldsGood
    • biomesGood

      protected Set<String> biomesGood
    • regionsBad

      protected Set<String> regionsBad
    • dropList

      protected List<DropItem> dropList
    • nonItemDrops

      protected Set<DropNonItem> nonItemDrops
  • Constructor Details

    • DropTable

      public DropTable(@NotNull Divinity plugin, @NotNull studio.magemonkey.codex.config.api.JYML cfg)
  • Method Details

    • save

      protected void save(@NotNull studio.magemonkey.codex.config.api.JYML cfg)
      Specified by:
      save in class studio.magemonkey.codex.manager.LoadableItem
    • getGroupName

      @NotNull public String getGroupName()
    • isRollOnce

      public boolean isRollOnce()
    • isLevelPenalty

      public boolean isLevelPenalty()
    • getPenaltyVariance

      public int getPenaltyVariance()
    • getAllowedWorlds

      @NotNull public Set<String> getAllowedWorlds()
    • getAllowedBiomes

      @NotNull public Set<String> getAllowedBiomes()
    • getDisallowedRegions

      @NotNull public Set<String> getDisallowedRegions()
    • getDrop

      @NotNull public List<DropItem> getDrop()
    • getNonItemDrops

      @NotNull public Set<DropNonItem> getNonItemDrops()
    • checkForLocation

      protected boolean checkForLocation(@NotNull org.bukkit.entity.LivingEntity npc)
      Parameters:
      npc - Instance of a valid entity
      Returns:
      True if drop is possible at this location.
    • canDrop

      protected boolean canDrop(@NotNull org.bukkit.entity.LivingEntity npc)
    • dropCalculator

      public Set<Drop> dropCalculator(@Nullable org.bukkit.entity.Player killer, @NotNull org.bukkit.entity.LivingEntity npc, float dropModifier)
      Specified by:
      dropCalculator in interface DropCalculator