From 9fab982e6a696cae445cb497b39ae4b716fddb4d Mon Sep 17 00:00:00 2001 From: Ellpeck Date: Sat, 9 May 2020 21:53:00 +0200 Subject: [PATCH] fixed some pipes loading chunks --- src/main/java/de/ellpeck/prettypipes/network/PipeNetwork.java | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/main/java/de/ellpeck/prettypipes/network/PipeNetwork.java b/src/main/java/de/ellpeck/prettypipes/network/PipeNetwork.java index 82c9f92..b29b0f2 100644 --- a/src/main/java/de/ellpeck/prettypipes/network/PipeNetwork.java +++ b/src/main/java/de/ellpeck/prettypipes/network/PipeNetwork.java @@ -143,6 +143,8 @@ public class PipeNetwork implements ICapabilitySerializable, GraphL return false; this.startProfile("find_destination"); for (BlockPos pipePos : this.getOrderedNetworkNodes(startPipePos)) { + if (!this.world.isBlockLoaded(pipePos)) + continue; PipeTileEntity pipe = this.getPipe(pipePos); BlockPos dest = pipe.getAvailableDestination(stack, false, preventOversending); if (dest == null || dest.equals(startInventory)) @@ -221,6 +223,8 @@ public class PipeNetwork implements ICapabilitySerializable, GraphL this.startProfile("get_network_items"); List info = new ArrayList<>(); for (BlockPos dest : this.getOrderedNetworkNodes(node)) { + if (!this.world.isBlockLoaded(dest)) + continue; PipeTileEntity pipe = this.getPipe(dest); if (!pipe.canNetworkSee()) continue;