aboutsummaryrefslogtreecommitdiffhomepage
path: root/patch-remap/mache-spigotflower-stripped/net/minecraft/world/Container.java.patch
blob: 7222f920794724f0bdbcb9d0ac7861998ef03659 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
--- a/net/minecraft/world/Container.java
+++ b/net/minecraft/world/Container.java
@@ -6,8 +6,12 @@
 import net.minecraft.world.entity.player.Player;
 import net.minecraft.world.item.Item;
 import net.minecraft.world.item.ItemStack;
+// CraftBukkit start
+import net.minecraft.world.item.crafting.RecipeHolder;
 import net.minecraft.world.level.Level;
 import net.minecraft.world.level.block.entity.BlockEntity;
+import org.bukkit.craftbukkit.entity.CraftHumanEntity;
+// CraftBukkit end
 
 public interface Container extends Clearable {
 
@@ -26,9 +30,7 @@
 
     void setItem(int slot, ItemStack stack);
 
-    default int getMaxStackSize() {
-        return 64;
-    }
+    int getMaxStackSize(); // CraftBukkit
 
     void setChanged();
 
@@ -88,4 +90,29 @@
 
         return level == null ? false : (level.getBlockEntity(blockpos) != blockentity ? false : player.distanceToSqr((double) blockpos.getX() + 0.5D, (double) blockpos.getY() + 0.5D, (double) blockpos.getZ() + 0.5D) <= (double) (i * i));
     }
+
+    // CraftBukkit start
+    java.util.List<ItemStack> getContents();
+
+    void onOpen(CraftHumanEntity who);
+
+    void onClose(CraftHumanEntity who);
+
+    java.util.List<org.bukkit.entity.HumanEntity> getViewers();
+
+    org.bukkit.inventory.InventoryHolder getOwner();
+
+    void setMaxStackSize(int size);
+
+    org.bukkit.Location getLocation();
+
+    default RecipeHolder<?> getCurrentRecipe() {
+        return null;
+    }
+
+    default void setCurrentRecipe(RecipeHolder<?> recipe) {
+    }
+
+    int MAX_STACK = 64;
+    // CraftBukkit end
 }