reduce p2p interface lags on bind and on pattern change
This commit is contained in:
lc-1337 committed 2025-07-20 12:32:36 +03:00
1 parent 10ee6f40ca
commit c3b180d27b
1 file changed
+9 -1
@@ -60,6 +60,7 @@ import appeng.helpers.DualityInterface;
import appeng.helpers.IInterfaceHost;
import appeng.helpers.IPriorityHost;
import appeng.me.GridAccessException;
import appeng.me.cache.CraftingGridCache;
import appeng.parts.automation.UpgradeInventory;
import appeng.parts.p2p.PartP2PTunnel;
import appeng.parts.p2p.PartP2PTunnelStatic;
@@ -83,12 +84,19 @@ public class PartFluidP2PInterface extends PartP2PTunnelStatic<PartFluidP2PInter
@Override
public void updateCraftingList() {
if (!isOutput()) {
CraftingGridCache.pauseRebuilds();
super.updateCraftingList();
try {
for (PartFluidP2PInterface p2p : getOutputs()) p2p.duality.updateCraftingList();
for (PartFluidP2PInterface p2p : getOutputs()) {
p2p.duality.updateCraftingList();
}
} catch (GridAccessException e) {
// ?
}
CraftingGridCache.unpauseRebuilds();
} else {
PartFluidP2PInterface p2p = getInput();
if (p2p != null) {