Merge pull request #2989 from glutzer/hose-pulley

Fix the hose pulley fill infinite option
This commit is contained in:
simibubi 2022-05-22 17:22:49 +02:00 committed by GitHub
commit 278837ecd3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -74,7 +74,7 @@ public class FluidFillingBehaviour extends FluidManipulationBehaviour {
(p, d) -> infinityCheckFrontier.add(new BlockPosEntry(p, d)), true);
int maxBlocks = maxBlocks();
if (infinityCheckVisited.size() > maxBlocks && maxBlocks != -1) {
if (infinityCheckVisited.size() > maxBlocks && maxBlocks != -1 && !fillInfinite()) {
if (!infinite) {
reset();
infinite = true;
@ -165,9 +165,11 @@ public class FluidFillingBehaviour extends FluidManipulationBehaviour {
if (visited.size() >= maxBlocks && maxBlocks != -1) {
infinite = true;
visited.clear();
queue.clear();
return false;
if (!fillInfinite()) {
visited.clear();
queue.clear();
return false;
}
}
SpaceType spaceType = getAtPos(world, currentPos, fluid);