mirror of
https://github.com/GTNewHorizons/Applied-Energistics-2-Unofficial.git
synced 2026-10-25 20:22:23 +00:00
Fix item duplication with mutating inventories (#1433)
This commit is contained in:
1 parent
9220db1fbe
commit
b5a8505978
1 file changed
+2
-1
@@ -248,11 +248,12 @@ public class AdaptorIInventory extends InventoryAdaptor {
|
||||
next.stackSize = Math.min(perOperationLimit, next.stackSize);
|
||||
|
||||
if (this.i.isItemValidForSlot(slot, next) && this.i.getStackInSlot(slot) == null) {
|
||||
final int inserted = next.stackSize;
|
||||
if (modulate) {
|
||||
this.i.setInventorySlotContents(slot, next);
|
||||
this.i.markDirty();
|
||||
}
|
||||
left.stackSize -= next.stackSize;
|
||||
left.stackSize -= inserted;
|
||||
|
||||
if (left.stackSize <= 0) {
|
||||
return null;
|
||||
|
||||
Reference in new issue
Block a user