forked from GeyserMC/Geyser
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);
|
session.sendDownstreamPacket(dropPacket);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
ItemStack item = session.getInventory().getItem(javaSlot);
|
ItemStack item = inventory.getItem(javaSlot);
|
||||||
if (item != null) {
|
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;
|
return;
|
||||||
} else { //clicking outside of inventory
|
} else { //clicking outside of inventory
|
||||||
|
|
Loading…
Reference in a new issue