fix outputs in processing terminal slowly migrating upwards

This commit is contained in:
PrototypeTrousers
2023-02-21 09:58:54 -03:00
parent c8a6d50ce3
commit bf1a3b7751
2 changed files with 14 additions and 4 deletions
@@ -262,8 +262,13 @@ public class ContainerWirelessPatternTerminal extends ContainerPatternEncoder im
ItemHandlerUtil.setStackInSlot(this.crafting, x, item == null ? ItemStack.EMPTY : item.createItemStack());
}
for (int x = 0; x < this.output.getSlots() && x < details.getOutputs().length; x++) {
final IAEItemStack item = details.getOutputs()[x];
for (int x = 0; x < this.output.getSlots(); x++) {
final IAEItemStack item;
if (x < details.getOutputs().length) {
item = details.getOutputs()[x];
} else {
item = null;
}
this.output.setStackInSlot(x, item == null ? ItemStack.EMPTY : item.createItemStack());
}
}
@@ -69,8 +69,13 @@ public abstract class AbstractPartEncoder extends AbstractPartTerminal {
this.crafting.setStackInSlot(x, item == null ? ItemStack.EMPTY : item.createItemStack());
}
for (int x = 0; x < this.output.getSlots() && x < details.getOutputs().length; x++) {
final IAEItemStack item = details.getOutputs()[x];
for (int x = 0; x < this.output.getSlots(); x++) {
final IAEItemStack item;
if (x < details.getOutputs().length) {
item = details.getOutputs()[x];
} else {
item = null;
}
this.output.setStackInSlot(x, item == null ? ItemStack.EMPTY : item.createItemStack());
}
}