#882 SAG Mill doesn't stop crafting silicon from sand when outputs

This commit is contained in:
CrazyPants committed 2014-08-16 22:58:05 +08:00
1 parent 14853652a6
commit f1d0c916d2
1 file changed
+9
@@ -262,13 +262,22 @@ public abstract class AbstractPoweredTaskEntity extends AbstractMachineEntity {
ResultStack[] nextResults = nextRecipe.getCompletedResult(chance, getInputs());
List<ItemStack> outputStacks = new ArrayList<ItemStack>(slotDefinition.getNumOutputSlots());
if(slotDefinition.getNumOutputSlots() > 0) {
boolean allFull = true;
for (int i = slotDefinition.minOutputSlot; i <= slotDefinition.maxOutputSlot; i++) {
ItemStack st = inventory[i];
if(st != null) {
st = st.copy();
if(allFull && st.stackSize < st.getMaxStackSize()) {
allFull = false;
}
} else {
allFull = false;
}
outputStacks.add(st);
}
if(allFull) {
return false;
}
}
for (ResultStack result : nextResults) {