Class ItemReward

java.lang.Object
com.Moshu.TreasureHunt.Components.Rewards.ItemReward

public class ItemReward extends Object
Represents an item reward that can be given to players during treasure hunts. This class manages the configuration and distribution of item rewards, supporting various item types including vanilla items, custom items from ItemsAdder, Oraxen, Nexo, and MMOItems.
  • Constructor Details

    • ItemReward

      public ItemReward()
  • Method Details

    • getIdentifier

      public String getIdentifier()
    • setIdentifier

      public void setIdentifier(String identifier)
    • getItemId

      public String getItemId()
    • setItemString

      public void setItemString(String item)
    • getRewardToTopX

      public int getRewardToTopX()
    • setRewardToTopX

      public void setRewardToTopX(int rewardToTopX)
    • isTopX

      public boolean isTopX(int currentTop)
    • shouldGiveOnlyToTopX

      public boolean shouldGiveOnlyToTopX()
    • getName

      public String getName()
    • setName

      public void setName(String name)
    • getLore

      public List<String> getLore()
    • setLore

      public void setLore(List<String> lore)
    • setEnchants

      public void setEnchants(List<String> enchants)
    • getAmount

      public int getAmount()
    • setAmount

      public void setAmount(int amount)
    • getChance

      public int getChance()
    • setChance

      public void setChance(int chance)
    • getRange

      public String getRange()
    • setRange

      public void setRange(String range)
    • getMenuItem

      public String getMenuItem()
    • setMenuItem

      public void setMenuItem(String menuItem)
    • isMMOItem

      public boolean isMMOItem()
    • isOraxen

      public boolean isOraxen()
    • isNexo

      public boolean isNexo()
    • isItemsAdder

      public boolean isItemsAdder()
    • build

      public ItemReward build()
    • getItemStack

      public org.bukkit.inventory.ItemStack getItemStack()
      Fetches the ItemReward object from the config and integrates with custom item plugins to retrieve the final custom ItemStack.
      Returns:
      the Bukkit ItemStack for this ItemReward