Skip to content

Commit 208667d

Browse files
committed
small fixes
1 parent 82a8853 commit 208667d

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/main/java/de/ellpeck/prettypipes/pipe/modules/craft/CraftingModuleItem.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -95,11 +95,11 @@ public void tick(ItemStack module, PipeBlockEntity tile) {
9595
s -> network.requestExistingItem(tile.getBlockPos(), dest.getLeft(), null, dest.getRight(), equalityTypes)).copy();
9696
// dest may be able to accept less than toRequest, so the amount that remains there also needs to be taken into account
9797
remain.grow(toRequest.getCount() - dest.getRight().getCount());
98-
if (remain.getCount() != dest.getRight().getCount()) {
98+
if (remain.getCount() != toRequest.getCount()) {
9999
ingredient.ifLeft(network::resolveNetworkLock);
100+
craft.ingredientsToRequest.removeFirst();
100101
if (!remain.isEmpty())
101-
craft.ingredientsToRequest.add(craft.ingredientsToRequest.indexOf(ingredient), Either.right(remain));
102-
craft.ingredientsToRequest.remove(ingredient);
102+
craft.ingredientsToRequest.addFirst(Either.right(remain));
103103
craft.travelingIngredients.add(toRequest.copyWithCount(toRequest.getCount() - remain.getCount()));
104104
craft.inProgress = true;
105105
}

0 commit comments

Comments
 (0)