20 lines
1.0 KiB
Diff
20 lines
1.0 KiB
Diff
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
From: Helvetica Volubi <suisuroru@blue-millennium.fun>
|
|
Date: Sat, 10 May 2025 19:46:16 +0800
|
|
Subject: [PATCH] Fix creative player item pick
|
|
|
|
|
|
diff --git a/net/minecraft/world/entity/item/ItemEntity.java b/net/minecraft/world/entity/item/ItemEntity.java
|
|
index 2309d1a30459ff986ab5bc4316247efaa7472a41..b745eb5d9c68547335247910ff2ae8d5fb36349c 100644
|
|
--- a/net/minecraft/world/entity/item/ItemEntity.java
|
|
+++ b/net/minecraft/world/entity/item/ItemEntity.java
|
|
@@ -417,7 +417,7 @@ public class ItemEntity extends Entity implements TraceableEntity {
|
|
Item item1 = item.getItem();
|
|
int count = item.getCount();
|
|
// CraftBukkit start - fire PlayerPickupItemEvent
|
|
- int canHold = entity.getInventory().canHold(item);
|
|
+ int canHold = entity.hasInfiniteMaterials() ? count : entity.getInventory().canHold(item); // Luminol - Fix creative item picking
|
|
int remaining = count - canHold;
|
|
boolean flyAtPlayer = false; // Paper
|
|
|