2018-07-15 02:00:00 +02:00
|
|
|
--- a/net/minecraft/server/FurnaceRecipe.java
|
|
|
|
+++ b/net/minecraft/server/FurnaceRecipe.java
|
2018-11-03 11:04:33 +01:00
|
|
|
@@ -2,6 +2,16 @@
|
2018-07-15 02:00:00 +02:00
|
|
|
|
|
|
|
import com.google.gson.JsonElement;
|
|
|
|
import com.google.gson.JsonObject;
|
2018-11-03 11:04:33 +01:00
|
|
|
+// CraftBukkit start
|
|
|
|
+import java.util.ArrayList;
|
|
|
|
+import java.util.List;
|
2018-07-15 02:00:00 +02:00
|
|
|
+import org.bukkit.craftbukkit.inventory.CraftFurnaceRecipe;
|
|
|
|
+import org.bukkit.craftbukkit.inventory.CraftItemStack;
|
2019-01-02 05:56:21 +01:00
|
|
|
+import org.bukkit.craftbukkit.inventory.CraftRecipe;
|
2018-11-03 11:04:33 +01:00
|
|
|
+import org.bukkit.craftbukkit.util.CraftMagicNumbers;
|
2018-07-15 02:00:00 +02:00
|
|
|
+import org.bukkit.craftbukkit.util.CraftNamespacedKey;
|
|
|
|
+import org.bukkit.inventory.Recipe;
|
2018-11-03 11:04:33 +01:00
|
|
|
+// CraftBukkit end
|
2018-07-15 02:00:00 +02:00
|
|
|
|
|
|
|
public class FurnaceRecipe implements IRecipe {
|
|
|
|
|
2019-01-02 05:56:21 +01:00
|
|
|
@@ -56,6 +66,16 @@
|
2018-07-15 02:00:00 +02:00
|
|
|
return this.key;
|
|
|
|
}
|
|
|
|
|
|
|
|
+ @Override
|
|
|
|
+ public Recipe toBukkitRecipe() {
|
|
|
|
+ CraftItemStack result = CraftItemStack.asCraftMirror(this.result);
|
|
|
|
+
|
2019-01-02 05:56:21 +01:00
|
|
|
+ CraftFurnaceRecipe recipe = new CraftFurnaceRecipe(CraftNamespacedKey.fromMinecraft(this.key), result, CraftRecipe.toBukkit(this.ingredient), this.experience, this.cookingTime);
|
2018-08-17 12:40:54 +02:00
|
|
|
+ recipe.setGroup(this.group);
|
|
|
|
+
|
|
|
|
+ return recipe;
|
2018-07-15 02:00:00 +02:00
|
|
|
+ }
|
|
|
|
+
|
|
|
|
public static class a implements RecipeSerializer<FurnaceRecipe> {
|
|
|
|
|
|
|
|
public a() {}
|