mirror of
https://github.com/Creators-of-Create/Create.git
synced 2025-01-27 13:28:00 +01:00
short circuit if 10k blocks have already been counted
This commit is contained in:
parent
b179ffba5e
commit
027f3a55bb
1 changed files with 3 additions and 0 deletions
|
@ -284,6 +284,9 @@ public class FluidDrainingBehaviour extends FluidManipulationBehaviour {
|
|||
for (BlockPos pos : visited) {
|
||||
if (getWorld().getFluidState(pos).isSource())
|
||||
sourceBlocks++;
|
||||
|
||||
if (sourceBlocks > maxBlocks)
|
||||
return;
|
||||
}
|
||||
|
||||
if (sourceBlocks > maxBlocks && canDrainInfinitely(fluid) && !queue.isEmpty()) {
|
||||
|
|
Loading…
Reference in a new issue