Skip to content

Commit 5d9c1b6

Browse files
authored
Fix machines accidentally locking multiple outputs (#968)
1 parent 31f4d27 commit 5d9c1b6

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

src/main/java/aztech/modern_industrialization/machines/components/CrafterComponent.java

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -534,8 +534,10 @@ protected boolean putItemOutputs(MachineRecipe recipe, boolean simulate, boolean
534534
} else {
535535
stack.increment(ins);
536536
}
537-
remainingAmount -= ins;
538-
537+
}
538+
remainingAmount -= ins;
539+
// ins changed inside of previous if, need to check again!
540+
if (ins > 0) {
539541
locksToToggle.add(stackId - 1);
540542
lockItems.add(output.variant().getItem());
541543
if (!simulate) {

0 commit comments

Comments
 (0)