Skip to content

Commit 138c6f3

Browse files
committed
Fix for ME Item Output Bus to not repeatedly attempt to export every tick if the bus is unable to export
1 parent c54ce3e commit 138c6f3

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

src/main/java/github/kasuminova/mmce/common/tile/MEItemOutputBus.java

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -102,9 +102,13 @@ public TickRateModulation tickingRequest(@Nonnull final IGridNode node, final in
102102

103103
if (aeStack.getStackSize() != left.getStackSize()) {
104104
successAtLeastOnce = true;
105+
failureCounter[slot] = 0;
106+
} else {
107+
failureCounter[slot] = Math.min(failureCounter[slot] + 1, 10);
105108
}
106109
} else {
107110
successAtLeastOnce = true;
111+
failureCounter[slot] = 0;
108112
}
109113
}
110114

@@ -125,10 +129,9 @@ public void markNoUpdate() {
125129
try {
126130
proxy.getTick().alertDevice(proxy.getNode());
127131
} catch (GridAccessException e) {
128-
// NO-OP
129132
}
130133
}
131134

132135
super.markNoUpdate();
133136
}
134-
}
137+
}

0 commit comments

Comments
 (0)