57dd397155
Upstream has released updates that appears to apply and compile correctly. This update has not been tested by PaperMC and as with ANY update, please do your own testing Bukkit Changes: b999860d SPIGOT-2304: Add LootGenerateEvent CraftBukkit Changes: 77fd87e4 SPIGOT-2304: Implement LootGenerateEvent a1a705ee SPIGOT-5566: Doused campfires & fires should call EntityChangeBlockEvent 41712edd SPIGOT-5707: PersistentDataHolder not Persistent on API dropped Item
24 lines
1.1 KiB
Diff
24 lines
1.1 KiB
Diff
From 0edef40fb8ea590b8a2db365016c780e8554fa68 Mon Sep 17 00:00:00 2001
|
|
From: Hugo Manrique <hugmanrique@gmail.com>
|
|
Date: Mon, 16 Jul 2018 12:42:20 +0200
|
|
Subject: [PATCH] Avoid item merge if stack size above max stack size
|
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/EntityItem.java b/src/main/java/net/minecraft/server/EntityItem.java
|
|
index 5efcc50ab9..e5c9bac88a 100644
|
|
--- a/src/main/java/net/minecraft/server/EntityItem.java
|
|
+++ b/src/main/java/net/minecraft/server/EntityItem.java
|
|
@@ -170,6 +170,10 @@ public class EntityItem extends Entity {
|
|
|
|
private void mergeNearby() {
|
|
if (this.w()) {
|
|
+ // Paper start - avoid item merge if stack size above max stack size
|
|
+ ItemStack stack = getItemStack();
|
|
+ if (stack.getCount() >= stack.getMaxStackSize()) return;
|
|
+ // Paper end
|
|
// Spigot start
|
|
double radius = world.spigotConfig.itemMerge;
|
|
List<EntityItem> list = this.world.a(EntityItem.class, this.getBoundingBox().grow(radius, radius, radius), (entityitem) -> {
|
|
--
|
|
2.26.2
|
|
|