Fix crafting (and server icon)

This commit is contained in:
Bjarne Koll
2024-10-25 22:33:37 +02:00
parent c0a178dc45
commit a02a757a57
2 changed files with 331 additions and 324 deletions

View File

@@ -33,6 +33,14 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
throw new IllegalArgumentException("Unknown recipe stack instance " + bukkit);
}
@@ -0,0 +0,0 @@ public interface CraftRecipe extends Recipe {
}
public static RecipeChoice toBukkit(Optional<Ingredient> list) {
- return list.map(CraftRecipe::toBukkit).orElse(null);
+ return list.map(CraftRecipe::toBukkit).orElse(RecipeChoice.empty()); // Paper - fix issue with recipe API
}
public static RecipeChoice toBukkit(Ingredient list) {
List<Holder<Item>> items = list.items();
if (items.isEmpty()) {