diff options
| author | Prometheus0000 <prometheus0000000@gmail.com> | 2020-12-03 15:02:06 -0500 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2020-12-03 15:02:06 -0500 |
| commit | 3ea02985a752745280981021bba93323ae39cf2c (patch) | |
| tree | 7b4a062b9bb3d98b09142db1d3f77774490f2466 /src/main/java/gregtech/api/util/GT_Utility.java | |
| parent | 926bcc78f0245bd894733ba629b9e3e4343b6aed (diff) | |
| parent | 26035bacd145da77b9b7109f574503cb41f302e1 (diff) | |
| download | GT5-Unofficial-3ea02985a752745280981021bba93323ae39cf2c.tar.gz GT5-Unofficial-3ea02985a752745280981021bba93323ae39cf2c.tar.bz2 GT5-Unofficial-3ea02985a752745280981021bba93323ae39cf2c.zip | |
Merge pull request #13 from GTNewHorizons/experimental
update
Diffstat (limited to 'src/main/java/gregtech/api/util/GT_Utility.java')
| -rw-r--r-- | src/main/java/gregtech/api/util/GT_Utility.java | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/main/java/gregtech/api/util/GT_Utility.java b/src/main/java/gregtech/api/util/GT_Utility.java index b06cc1d82a..05e0874e7a 100644 --- a/src/main/java/gregtech/api/util/GT_Utility.java +++ b/src/main/java/gregtech/api/util/GT_Utility.java @@ -546,13 +546,14 @@ public class GT_Utility { for (int tGrabSlot = 0;tGrabSlot<tGrabInventorySize;tGrabSlot++) { //ItemStack tInventoryStack : mInventory - int tMovedItems = 0; + int tMovedItems; do { + tMovedItems = 0; ItemStack tGrabStack = aTileEntity1.getStackInSlot(tGrabSlot); if (listContainsItem(aFilter, tGrabStack, true, aInvertFilter) && (tGrabStack.stackSize >= aMinMoveAtOnce && isAllowedToTakeFromSlot(aTileEntity1, tGrabSlot, aGrabFrom, tGrabStack))) { int tStackSize = tGrabStack.stackSize; - tMovedItems = 0; + for (int tPutSlot = tFirstsValidSlot; tPutSlot < tPutInventorySize; tPutSlot++) { if (isAllowedToPutIntoSlot(tPutInventory, tPutSlot, aPutTo, tGrabStack, (byte) 64)) { int tMoved = moveStackFromSlotAToSlotB(aTileEntity1, tPutInventory, tGrabSlot, tPutSlot, aMaxTargetStackSize, aMinTargetStackSize, (byte) (aMaxMoveAtOnce - tMovedItems), aMinMoveAtOnce); |
