@@ -1,6 +1,6 @@
|
||||
--- a/net/minecraft/server/CraftingManager.java
|
||||
+++ b/net/minecraft/server/CraftingManager.java
|
||||
@@ -23,11 +23,13 @@
|
||||
--- a/net/minecraft/world/item/crafting/CraftingManager.java
|
||||
+++ b/net/minecraft/world/item/crafting/CraftingManager.java
|
||||
@@ -34,11 +34,13 @@
|
||||
import org.apache.logging.log4j.LogManager;
|
||||
import org.apache.logging.log4j.Logger;
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
private boolean d;
|
||||
|
||||
public CraftingManager() {
|
||||
@@ -36,7 +38,12 @@
|
||||
@@ -47,7 +49,12 @@
|
||||
|
||||
protected void a(Map<MinecraftKey, JsonElement> map, IResourceManager iresourcemanager, GameProfilerFiller gameprofilerfiller) {
|
||||
this.d = false;
|
||||
@@ -29,7 +29,7 @@
|
||||
Iterator iterator = map.entrySet().iterator();
|
||||
|
||||
while (iterator.hasNext()) {
|
||||
@@ -46,24 +53,42 @@
|
||||
@@ -57,24 +64,42 @@
|
||||
try {
|
||||
IRecipe<?> irecipe = a(minecraftkey, ChatDeserializer.m((JsonElement) entry.getValue(), "top element"));
|
||||
|
||||
@@ -77,7 +77,7 @@
|
||||
}
|
||||
|
||||
public <C extends IInventory, T extends IRecipe<C>> List<T> a(Recipes<T> recipes) {
|
||||
@@ -81,7 +106,7 @@
|
||||
@@ -92,7 +117,7 @@
|
||||
}
|
||||
|
||||
private <C extends IInventory, T extends IRecipe<C>> Map<MinecraftKey, IRecipe<C>> b(Recipes<T> recipes) {
|
||||
@@ -86,7 +86,7 @@
|
||||
}
|
||||
|
||||
public <C extends IInventory, T extends IRecipe<C>> NonNullList<ItemStack> c(Recipes<T> recipes, C c0, World world) {
|
||||
@@ -102,7 +127,7 @@
|
||||
@@ -113,7 +138,7 @@
|
||||
|
||||
public Optional<? extends IRecipe<?>> getRecipe(MinecraftKey minecraftkey) {
|
||||
return this.recipes.values().stream().map((map) -> {
|
||||
@@ -95,7 +95,7 @@
|
||||
}).filter(Objects::nonNull).findFirst();
|
||||
}
|
||||
|
||||
@@ -125,4 +150,14 @@
|
||||
@@ -136,4 +161,14 @@
|
||||
return new JsonSyntaxException("Invalid or unsupported recipe type '" + s + "'");
|
||||
})).a(minecraftkey, jsonobject);
|
||||
}
|
||||
|
||||
@@ -1,7 +1,8 @@
|
||||
--- a/net/minecraft/server/FurnaceRecipe.java
|
||||
+++ b/net/minecraft/server/FurnaceRecipe.java
|
||||
@@ -1,5 +1,13 @@
|
||||
package net.minecraft.server;
|
||||
--- a/net/minecraft/world/item/crafting/FurnaceRecipe.java
|
||||
+++ b/net/minecraft/world/item/crafting/FurnaceRecipe.java
|
||||
@@ -3,6 +3,14 @@
|
||||
import net.minecraft.resources.MinecraftKey;
|
||||
import net.minecraft.world.item.ItemStack;
|
||||
|
||||
+// CraftBukkit start
|
||||
+import org.bukkit.craftbukkit.inventory.CraftFurnaceRecipe;
|
||||
@@ -14,7 +15,7 @@
|
||||
public class FurnaceRecipe extends RecipeCooking {
|
||||
|
||||
public FurnaceRecipe(MinecraftKey minecraftkey, String s, RecipeItemStack recipeitemstack, ItemStack itemstack, float f, int i) {
|
||||
@@ -10,4 +18,14 @@
|
||||
@@ -13,4 +21,14 @@
|
||||
public RecipeSerializer<?> getRecipeSerializer() {
|
||||
return RecipeSerializer.p;
|
||||
}
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
--- a/net/minecraft/server/IRecipe.java
|
||||
+++ b/net/minecraft/server/IRecipe.java
|
||||
@@ -35,4 +35,6 @@
|
||||
--- a/net/minecraft/world/item/crafting/IRecipe.java
|
||||
+++ b/net/minecraft/world/item/crafting/IRecipe.java
|
||||
@@ -42,4 +42,6 @@
|
||||
RecipeSerializer<?> getRecipeSerializer();
|
||||
|
||||
Recipes<?> g();
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
--- a/net/minecraft/server/IRecipeComplex.java
|
||||
+++ b/net/minecraft/server/IRecipeComplex.java
|
||||
@@ -22,4 +22,11 @@
|
||||
--- a/net/minecraft/world/item/crafting/IRecipeComplex.java
|
||||
+++ b/net/minecraft/world/item/crafting/IRecipeComplex.java
|
||||
@@ -25,4 +25,11 @@
|
||||
public ItemStack getResult() {
|
||||
return ItemStack.b;
|
||||
}
|
||||
|
||||
@@ -1,7 +1,8 @@
|
||||
--- a/net/minecraft/server/RecipeBlasting.java
|
||||
+++ b/net/minecraft/server/RecipeBlasting.java
|
||||
@@ -1,5 +1,13 @@
|
||||
package net.minecraft.server;
|
||||
--- a/net/minecraft/world/item/crafting/RecipeBlasting.java
|
||||
+++ b/net/minecraft/world/item/crafting/RecipeBlasting.java
|
||||
@@ -3,6 +3,14 @@
|
||||
import net.minecraft.resources.MinecraftKey;
|
||||
import net.minecraft.world.item.ItemStack;
|
||||
|
||||
+// CraftBukkit start
|
||||
+import org.bukkit.craftbukkit.inventory.CraftBlastingRecipe;
|
||||
@@ -14,7 +15,7 @@
|
||||
public class RecipeBlasting extends RecipeCooking {
|
||||
|
||||
public RecipeBlasting(MinecraftKey minecraftkey, String s, RecipeItemStack recipeitemstack, ItemStack itemstack, float f, int i) {
|
||||
@@ -10,4 +18,16 @@
|
||||
@@ -13,4 +21,16 @@
|
||||
public RecipeSerializer<?> getRecipeSerializer() {
|
||||
return RecipeSerializer.q;
|
||||
}
|
||||
|
||||
@@ -1,7 +1,8 @@
|
||||
--- a/net/minecraft/server/RecipeCampfire.java
|
||||
+++ b/net/minecraft/server/RecipeCampfire.java
|
||||
@@ -1,5 +1,13 @@
|
||||
package net.minecraft.server;
|
||||
--- a/net/minecraft/world/item/crafting/RecipeCampfire.java
|
||||
+++ b/net/minecraft/world/item/crafting/RecipeCampfire.java
|
||||
@@ -3,6 +3,14 @@
|
||||
import net.minecraft.resources.MinecraftKey;
|
||||
import net.minecraft.world.item.ItemStack;
|
||||
|
||||
+// CraftBukkit start
|
||||
+import org.bukkit.craftbukkit.inventory.CraftCampfireRecipe;
|
||||
@@ -14,7 +15,7 @@
|
||||
public class RecipeCampfire extends RecipeCooking {
|
||||
|
||||
public RecipeCampfire(MinecraftKey minecraftkey, String s, RecipeItemStack recipeitemstack, ItemStack itemstack, float f, int i) {
|
||||
@@ -10,4 +18,16 @@
|
||||
@@ -13,4 +21,16 @@
|
||||
public RecipeSerializer<?> getRecipeSerializer() {
|
||||
return RecipeSerializer.s;
|
||||
}
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
--- a/net/minecraft/server/RecipeItemStack.java
|
||||
+++ b/net/minecraft/server/RecipeItemStack.java
|
||||
@@ -25,6 +25,7 @@
|
||||
--- a/net/minecraft/world/item/crafting/RecipeItemStack.java
|
||||
+++ b/net/minecraft/world/item/crafting/RecipeItemStack.java
|
||||
@@ -35,6 +35,7 @@
|
||||
private final RecipeItemStack.Provider[] b;
|
||||
public ItemStack[] choices;
|
||||
private IntList d;
|
||||
@@ -8,7 +8,7 @@
|
||||
|
||||
public RecipeItemStack(Stream<? extends RecipeItemStack.Provider> stream) {
|
||||
this.b = (RecipeItemStack.Provider[]) stream.toArray((i) -> {
|
||||
@@ -57,6 +58,15 @@
|
||||
@@ -67,6 +68,15 @@
|
||||
for (int j = 0; j < i; ++j) {
|
||||
ItemStack itemstack1 = aitemstack[j];
|
||||
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
--- a/net/minecraft/server/RecipeSmithing.java
|
||||
+++ b/net/minecraft/server/RecipeSmithing.java
|
||||
@@ -3,6 +3,14 @@
|
||||
import com.google.gson.JsonElement;
|
||||
import com.google.gson.JsonObject;
|
||||
--- a/net/minecraft/world/item/crafting/RecipeSmithing.java
|
||||
+++ b/net/minecraft/world/item/crafting/RecipeSmithing.java
|
||||
@@ -10,6 +10,14 @@
|
||||
import net.minecraft.world.item.ItemStack;
|
||||
import net.minecraft.world.level.World;
|
||||
|
||||
+// CraftBukkit start
|
||||
+import org.bukkit.craftbukkit.inventory.CraftItemStack;
|
||||
@@ -15,7 +15,7 @@
|
||||
public class RecipeSmithing implements IRecipe<IInventory> {
|
||||
|
||||
private final RecipeItemStack a;
|
||||
@@ -58,6 +66,17 @@
|
||||
@@ -65,6 +73,17 @@
|
||||
return Recipes.SMITHING;
|
||||
}
|
||||
|
||||
|
||||
@@ -1,7 +1,8 @@
|
||||
--- a/net/minecraft/server/RecipeSmoking.java
|
||||
+++ b/net/minecraft/server/RecipeSmoking.java
|
||||
@@ -1,5 +1,13 @@
|
||||
package net.minecraft.server;
|
||||
--- a/net/minecraft/world/item/crafting/RecipeSmoking.java
|
||||
+++ b/net/minecraft/world/item/crafting/RecipeSmoking.java
|
||||
@@ -3,6 +3,14 @@
|
||||
import net.minecraft.resources.MinecraftKey;
|
||||
import net.minecraft.world.item.ItemStack;
|
||||
|
||||
+// CraftBukkit start
|
||||
+import org.bukkit.craftbukkit.inventory.CraftItemStack;
|
||||
@@ -14,7 +15,7 @@
|
||||
public class RecipeSmoking extends RecipeCooking {
|
||||
|
||||
public RecipeSmoking(MinecraftKey minecraftkey, String s, RecipeItemStack recipeitemstack, ItemStack itemstack, float f, int i) {
|
||||
@@ -10,4 +18,16 @@
|
||||
@@ -13,4 +21,16 @@
|
||||
public RecipeSerializer<?> getRecipeSerializer() {
|
||||
return RecipeSerializer.r;
|
||||
}
|
||||
|
||||
@@ -1,7 +1,8 @@
|
||||
--- a/net/minecraft/server/RecipeStonecutting.java
|
||||
+++ b/net/minecraft/server/RecipeStonecutting.java
|
||||
@@ -1,5 +1,13 @@
|
||||
package net.minecraft.server;
|
||||
--- a/net/minecraft/world/item/crafting/RecipeStonecutting.java
|
||||
+++ b/net/minecraft/world/item/crafting/RecipeStonecutting.java
|
||||
@@ -5,6 +5,14 @@
|
||||
import net.minecraft.world.item.ItemStack;
|
||||
import net.minecraft.world.level.World;
|
||||
|
||||
+// CraftBukkit start
|
||||
+import org.bukkit.craftbukkit.inventory.CraftItemStack;
|
||||
@@ -14,7 +15,7 @@
|
||||
public class RecipeStonecutting extends RecipeSingleItem {
|
||||
|
||||
public RecipeStonecutting(MinecraftKey minecraftkey, String s, RecipeItemStack recipeitemstack, ItemStack itemstack) {
|
||||
@@ -10,4 +18,16 @@
|
||||
@@ -15,4 +23,16 @@
|
||||
public boolean a(IInventory iinventory, World world) {
|
||||
return this.ingredient.test(iinventory.getItem(0));
|
||||
}
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
--- a/net/minecraft/server/ShapedRecipes.java
|
||||
+++ b/net/minecraft/server/ShapedRecipes.java
|
||||
@@ -13,6 +13,13 @@
|
||||
import java.util.Map.Entry;
|
||||
import java.util.Set;
|
||||
--- a/net/minecraft/world/item/crafting/ShapedRecipes.java
|
||||
+++ b/net/minecraft/world/item/crafting/ShapedRecipes.java
|
||||
@@ -22,6 +22,13 @@
|
||||
import net.minecraft.world.item.ItemStack;
|
||||
import net.minecraft.world.level.World;
|
||||
|
||||
+// CraftBukkit start
|
||||
+import org.bukkit.craftbukkit.inventory.CraftItemStack;
|
||||
@@ -14,7 +14,7 @@
|
||||
public class ShapedRecipes implements RecipeCrafting {
|
||||
|
||||
private final int width;
|
||||
@@ -31,6 +38,66 @@
|
||||
@@ -40,6 +47,66 @@
|
||||
this.result = itemstack;
|
||||
}
|
||||
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
--- a/net/minecraft/server/ShapelessRecipes.java
|
||||
+++ b/net/minecraft/server/ShapelessRecipes.java
|
||||
@@ -6,6 +6,12 @@
|
||||
import it.unimi.dsi.fastutil.ints.IntList;
|
||||
import java.util.Iterator;
|
||||
--- a/net/minecraft/world/item/crafting/ShapelessRecipes.java
|
||||
+++ b/net/minecraft/world/item/crafting/ShapelessRecipes.java
|
||||
@@ -14,6 +14,12 @@
|
||||
import net.minecraft.world.item.ItemStack;
|
||||
import net.minecraft.world.level.World;
|
||||
|
||||
+// CraftBukkit start
|
||||
+import org.bukkit.craftbukkit.inventory.CraftItemStack;
|
||||
@@ -13,7 +13,7 @@
|
||||
public class ShapelessRecipes implements RecipeCrafting {
|
||||
|
||||
private final MinecraftKey key;
|
||||
@@ -20,6 +26,20 @@
|
||||
@@ -28,6 +34,20 @@
|
||||
this.ingredients = nonnulllist;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user