From 346ae4c4944aaae006cc0b827573228c5e5e8dc7 Mon Sep 17 00:00:00 2001 From: carm Date: Sat, 18 Jun 2022 06:00:39 +0800 Subject: [PATCH] =?UTF-8?q?feat(item):=20=E4=B8=BAItemConfig=E6=B7=BB?= =?UTF-8?q?=E5=8A=A0=20ItemFlag=20=E4=B8=8E=20enchant=20=E7=9B=B8=E5=85=B3?= =?UTF-8?q?=E9=85=8D=E7=BD=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../mineconfiguration/bukkit/data/ItemConfig.java | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/platform/bukkit/base/src/main/java/cc/carm/lib/mineconfiguration/bukkit/data/ItemConfig.java b/platform/bukkit/base/src/main/java/cc/carm/lib/mineconfiguration/bukkit/data/ItemConfig.java index d3d494e..6124ec1 100644 --- a/platform/bukkit/base/src/main/java/cc/carm/lib/mineconfiguration/bukkit/data/ItemConfig.java +++ b/platform/bukkit/base/src/main/java/cc/carm/lib/mineconfiguration/bukkit/data/ItemConfig.java @@ -24,6 +24,19 @@ public class ItemConfig { protected @NotNull Map enchants; protected @NotNull Set flags; + public ItemConfig(@NotNull Material type, @Nullable String name) { + this(type, name, Collections.emptyList()); + } + + public ItemConfig(@NotNull Material type, @Nullable String name, @NotNull List lore) { + this(type, (short) 0, name, lore); + } + + public ItemConfig(@NotNull Material type, short damage, + @Nullable String name, @NotNull List lore) { + this(type, damage, name, lore, Collections.emptyMap(), Collections.emptySet()); + } + public ItemConfig(@NotNull Material type, short damage, @Nullable String name, @NotNull List lore, @NotNull Map enchants,