PocketMine-MP 5.23.3 git-f7687af337d001ddbcc47b8e773f014a33faa662
Loading...
Searching...
No Matches
pocketmine\block\utils\MinimumCostFlowCalculator Class Reference
+ Collaboration diagram for pocketmine\block\utils\MinimumCostFlowCalculator:

Public Member Functions

 __construct (private World $world, private int $flowDecayPerBlock, private \Closure $canFlowInto)
 
 getOptimalFlowDirections (int $originX, int $originY, int $originZ)
 

Detailed Description

Calculates the path(s) of least resistance for liquid flow.

Definition at line 36 of file MinimumCostFlowCalculator.php.

Constructor & Destructor Documentation

◆ __construct()

pocketmine\block\utils\MinimumCostFlowCalculator::__construct ( private World $world,
private int $flowDecayPerBlock,
private \Closure $canFlowInto )

@phpstan-param \Closure(Block) : bool $canFlowInto

Definition at line 48 of file MinimumCostFlowCalculator.php.

Member Function Documentation

◆ getOptimalFlowDirections()

pocketmine\block\utils\MinimumCostFlowCalculator::getOptimalFlowDirections ( int $originX,
int $originY,
int $originZ )
Returns
int[]

Definition at line 101 of file MinimumCostFlowCalculator.php.


The documentation for this class was generated from the following file: