mirror of
https://github.com/GeyserMC/Geyser.git
synced 2024-08-14 23:57:35 +00:00
Fix bug when dropping items from an open inventory
This commit is contained in:
parent
0daa4451ec
commit
ab71bf0727
1 changed files with 2 additions and 2 deletions
|
@ -120,9 +120,9 @@ public class InventoryActionDataTranslator {
|
|||
session.sendDownstreamPacket(dropPacket);
|
||||
}
|
||||
}
|
||||
ItemStack item = session.getInventory().getItem(javaSlot);
|
||||
ItemStack item = inventory.getItem(javaSlot);
|
||||
if (item != null) {
|
||||
session.getInventory().setItem(javaSlot, new ItemStack(item.getId(), item.getAmount() - dropAmount, item.getNbt()));
|
||||
inventory.setItem(javaSlot, new ItemStack(item.getId(), item.getAmount() - dropAmount, item.getNbt()));
|
||||
}
|
||||
return;
|
||||
} else { //clicking outside of inventory
|
||||
|
|
Loading…
Reference in a new issue