From 18d9018796ffa952df5d256c27a29b67ead1f79c Mon Sep 17 00:00:00 2001 From: zhangyuheng Date: Fri, 19 Apr 2024 09:55:36 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E4=BA=86=E9=9A=90=E5=BD=A2?= =?UTF-8?q?=E5=8F=91=E5=85=89=E5=B1=95=E7=A4=BA=E6=A1=86=E5=90=88=E6=88=90?= =?UTF-8?q?=E8=A1=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- README.md | 4 ++-- pom.xml | 2 +- .../essentialsd/recipes/InvisibleGlowItemFrame.java | 11 +++++------ 3 files changed, 8 insertions(+), 9 deletions(-) diff --git a/README.md b/README.md index 0270616..2901e2e 100644 --- a/README.md +++ b/README.md @@ -24,9 +24,9 @@ EssentialsX,其中D代表Deer。 ![image-20240118174020596](https://ssl.lunadeer.cn:14437/i/2024/01/18/65a8f204dcb15.png) -可以通过`八个木棍`+`一个玻璃板`合成隐形展示框![](https://ssl.lunadeer.cn:14437/i/2024/01/16/65a62829e167b.png) +可以通过`八个木棍`+`一个玻璃板`合成隐形展示框![](https://ssl.lunadeer.cn:14437/i/2024/04/19/6621ce4eeabbf.png) -或者`八个烈焰棒`+`一个玻璃板`合成隐形发光展示框![](https://ssl.lunadeer.cn:14437/i/2024/01/16/65a628356722d.png) +或者`一个隐形展示框`+`一个萤石粉`合成隐形发光展示框![](https://ssl.lunadeer.cn:14437/i/2024/04/19/6621ce915ef3c.png) 当隐形展示框中没有东西时和普通展示框没有区别,**只有在将要展示的物品放置在隐形展示框中时展示框才会自动隐形** 。取下展示框中的物品后展示框会自动恢复到现形状态,避免找不到隐形的空展示框。 diff --git a/pom.xml b/pom.xml index 05f72df..77e7b6f 100644 --- a/pom.xml +++ b/pom.xml @@ -6,7 +6,7 @@ cn.lunadeer EssentialsD - 1.15.8 + 1.15.10 jar EssentialsD diff --git a/src/main/java/cn/lunadeer/essentialsd/recipes/InvisibleGlowItemFrame.java b/src/main/java/cn/lunadeer/essentialsd/recipes/InvisibleGlowItemFrame.java index 61af2cd..f520d28 100644 --- a/src/main/java/cn/lunadeer/essentialsd/recipes/InvisibleGlowItemFrame.java +++ b/src/main/java/cn/lunadeer/essentialsd/recipes/InvisibleGlowItemFrame.java @@ -6,6 +6,7 @@ import org.bukkit.Material; import org.bukkit.NamespacedKey; import org.bukkit.inventory.ItemStack; import org.bukkit.inventory.ShapedRecipe; +import org.bukkit.inventory.ShapelessRecipe; import org.bukkit.inventory.meta.ItemMeta; import org.bukkit.persistence.PersistentDataType; @@ -13,14 +14,12 @@ import java.util.ArrayList; import java.util.List; public class InvisibleGlowItemFrame { - - public static ShapedRecipe getRecipe() { + public static ShapelessRecipe getRecipe() { NamespacedKey key = new NamespacedKey(EssentialsD.instance, "invisible_glow_item_frame"); ItemStack item = getItemStack(); - ShapedRecipe recipe = new ShapedRecipe(key, item); - recipe.shape("sss","sgs","sss"); - recipe.setIngredient('s',Material.BLAZE_ROD); - recipe.setIngredient('g',Material.GLASS_PANE); + ShapelessRecipe recipe = new ShapelessRecipe(key, item); + recipe.addIngredient(InvisibleItemFrame.getItemStack()); + recipe.addIngredient(Material.GLOWSTONE_DUST); return recipe; }