summaryrefslogtreecommitdiffstats
path: root/nms-patches/RecipesBanner.patch
diff options
context:
space:
mode:
Diffstat (limited to 'nms-patches/RecipesBanner.patch')
-rw-r--r--nms-patches/RecipesBanner.patch31
1 files changed, 17 insertions, 14 deletions
diff --git a/nms-patches/RecipesBanner.patch b/nms-patches/RecipesBanner.patch
index 3de6f89e..06e3cbee 100644
--- a/nms-patches/RecipesBanner.patch
+++ b/nms-patches/RecipesBanner.patch
@@ -1,32 +1,35 @@
--- a/net/minecraft/server/RecipesBanner.java
+++ b/net/minecraft/server/RecipesBanner.java
-@@ -20,9 +20,13 @@
- craftingmanager.a(new RecipesBanner.AddRecipe(null));
- }
+@@ -2,9 +2,16 @@
+
+ import javax.annotation.Nullable;
-- static class AddRecipe implements IRecipe {
-+ static class AddRecipe extends ShapelessRecipes implements IRecipe { // CraftBukkit - added extends
+-public class RecipesBanner { public static class AddRecipe extends IRecipe {
++// CraftBukkit - decompile weirdness
++public class RecipesBanner {
-- private AddRecipe() {}
+- public AddRecipe() {}
++ public static class AddRecipe extends ShapelessRecipes { // CraftBukkit
++
+ // CraftBukkit start - Delegate to new parent class with bogus info
-+ private AddRecipe() {
-+ super(new ItemStack(Items.BANNER, 0, 0), java.util.Arrays.asList(new ItemStack(Items.BANNER)));
++ public AddRecipe() {
++ super("", new ItemStack(Items.BANNER, 0, 0), NonNullList.a(RecipeItemStack.a, RecipeItemStack.a(Items.BANNER)));
+ }
+ // CraftBukkit end
public boolean a(InventoryCrafting inventorycrafting, World world) {
boolean flag = false;
-@@ -208,9 +212,13 @@
+@@ -186,9 +193,13 @@
}
}
-- static class DuplicateRecipe implements IRecipe {
-+ static class DuplicateRecipe extends ShapelessRecipes implements IRecipe { // CraftBukkit - added extends
+- public static class DuplicateRecipe extends IRecipe {
++ public static class DuplicateRecipe extends ShapelessRecipes { // CraftBukkit - added extends
-- private DuplicateRecipe() {}
+- public DuplicateRecipe() {}
+ // CraftBukkit start - Delegate to new parent class with bogus info
-+ private DuplicateRecipe() {
-+ super(new ItemStack(Items.BANNER, 0, 0), java.util.Arrays.asList(new ItemStack(Items.DYE, 0, 5)));
++ public DuplicateRecipe() {
++ super("", new ItemStack(Items.BANNER, 0, 0), NonNullList.a(RecipeItemStack.a, RecipeItemStack.a(Items.DYE)));
+ }
+ // CraftBukkit end