Mirror von
https://github.com/PaperMC/Paper.git
synchronisiert 2024-12-15 02:50:09 +01:00
SPIGOT-4556: Fix plugins closing inventory during drop events
Dieser Commit ist enthalten in:
Ursprung
5be2ddcbd5
Commit
c4a67eed99
@ -126,7 +126,20 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else if (inventoryclicktype == InventoryClickType.SWAP && j >= 0 && j < 9) {
|
} else if (inventoryclicktype == InventoryClickType.SWAP && j >= 0 && j < 9) {
|
||||||
@@ -565,6 +637,7 @@
|
@@ -356,8 +428,11 @@
|
||||||
|
PlayerInventory playerinventory = entityhuman.inventory;
|
||||||
|
|
||||||
|
if (!playerinventory.getCarried().isEmpty()) {
|
||||||
|
- entityhuman.drop(playerinventory.getCarried(), false);
|
||||||
|
+ // CraftBukkit start - SPIGOT-4556
|
||||||
|
+ ItemStack carried = playerinventory.getCarried();
|
||||||
|
playerinventory.setCarried(ItemStack.a);
|
||||||
|
+ entityhuman.drop(carried, false);
|
||||||
|
+ // CraftBukkit end
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
@@ -565,6 +640,7 @@
|
||||||
if (inventorycraftresult.a(world, entityplayer, irecipe) && irecipe != null) {
|
if (inventorycraftresult.a(world, entityplayer, irecipe) && irecipe != null) {
|
||||||
itemstack = irecipe.craftItem(iinventory);
|
itemstack = irecipe.craftItem(iinventory);
|
||||||
}
|
}
|
||||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren