diff --git a/src/main/java/net/Indyuce/mmocore/api/item/ConfigItem.java b/src/main/java/net/Indyuce/mmocore/api/item/ConfigItem.java index c0ecedb6..eb75c48c 100644 --- a/src/main/java/net/Indyuce/mmocore/api/item/ConfigItem.java +++ b/src/main/java/net/Indyuce/mmocore/api/item/ConfigItem.java @@ -77,6 +77,10 @@ public class ConfigItem { public String getName() { return name; } + + public int getModelData() { + return modeldata; + } public String getId() { return id; diff --git a/src/main/java/net/Indyuce/mmocore/api/item/CurrencyItem.java b/src/main/java/net/Indyuce/mmocore/api/item/CurrencyItem.java index db088eae..4efc4357 100644 --- a/src/main/java/net/Indyuce/mmocore/api/item/CurrencyItem.java +++ b/src/main/java/net/Indyuce/mmocore/api/item/CurrencyItem.java @@ -7,6 +7,7 @@ import org.bukkit.inventory.ItemFlag; import org.bukkit.inventory.ItemStack; import org.bukkit.inventory.meta.ItemMeta; +import net.Indyuce.mmocore.MMOCore; import net.Indyuce.mmocore.version.nms.ItemTag; public class CurrencyItem extends ConfigItem { @@ -34,6 +35,9 @@ public class CurrencyItem extends ConfigItem { getLore().forEach(line -> lore.add(format(line))); meta.setLore(lore); + if(MMOCore.plugin.version.isStrictlyHigher(1, 13)) + meta.setCustomModelData(getModelData()); + item.setItemMeta(meta); return NBTItem.get(item).add(new ItemTag("RpgWorth", worth)).toItem(); }