geforkt von Mirrors/Paper
Fix a bug in recipe books that prevented them from working as they should
Dieser Commit ist enthalten in:
Ursprung
89ff242bd4
Commit
8d26bacb73
@ -5,7 +5,7 @@ Subject: [PATCH] Fix Recipe Books
|
||||
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/PlayerConnection.java b/src/main/java/net/minecraft/server/PlayerConnection.java
|
||||
index 682211cdd..0b0a34508 100644
|
||||
index 682211cdd..1fed465bf 100644
|
||||
--- a/src/main/java/net/minecraft/server/PlayerConnection.java
|
||||
+++ b/src/main/java/net/minecraft/server/PlayerConnection.java
|
||||
@@ -0,0 +0,0 @@ public class PlayerConnection implements PacketListenerPlayIn, ITickable {
|
||||
@ -27,8 +27,9 @@ index 682211cdd..0b0a34508 100644
|
||||
itemstack = this.player.activeContainer.getSlot(packetplayinautorecipe_a.b).getItem();
|
||||
- if (this.a(packetplayinautorecipe_a.a, itemstack)) {
|
||||
+ // Paper start - improve validation
|
||||
+ ItemStack to = this.player.activeContainer.getSlot(packetplayinautorecipe_a.c).getItem();
|
||||
+ if (this.a(packetplayinautorecipe_a.a, itemstack) && (to.isEmpty() || this.a(packetplayinautorecipe_a.a, to))) {
|
||||
+ ItemStack to = this.player.inventory.getItem(packetplayinautorecipe_a.c);
|
||||
+ ItemStack ref = packetplayinautorecipe_a.a;
|
||||
+ if (this.a(ref, itemstack) && (to.isEmpty() || this.a(ref, to)) && (ref.getCount() + to.getCount() <= ref.getMaxStackSize())) {
|
||||
+ // Paper end
|
||||
i = packetplayinautorecipe_a.a.getCount();
|
||||
if (packetplayinautorecipe_a.c == -1) {
|
||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren