geforkt von Mirrors/Paper
SPIGOT-4940: Fletcher villager gifts sometimes crash server
By: md_5 <git@md-5.net>
Dieser Commit ist enthalten in:
Ursprung
609921674a
Commit
6b35a00cff
14
paper-server/nms-patches/LootTable.patch
Normale Datei
14
paper-server/nms-patches/LootTable.patch
Normale Datei
@ -0,0 +1,14 @@
|
|||||||
|
--- a/net/minecraft/server/LootTable.java
|
||||||
|
+++ b/net/minecraft/server/LootTable.java
|
||||||
|
@@ -40,6 +40,11 @@
|
||||||
|
|
||||||
|
public static Consumer<ItemStack> a(Consumer<ItemStack> consumer) {
|
||||||
|
return (itemstack) -> {
|
||||||
|
+ // CraftBukkit start - SPIGOT-4940: no empty loot
|
||||||
|
+ if (itemstack.isEmpty()) {
|
||||||
|
+ return;
|
||||||
|
+ }
|
||||||
|
+ // CraftBukkit end
|
||||||
|
if (itemstack.getCount() < itemstack.getMaxStackSize()) {
|
||||||
|
consumer.accept(itemstack);
|
||||||
|
} else {
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren