Aquifer 5.46.0
Noise-based aquifers: local water/lava levels in 16x12x16 cells with barriers between them (vanilla 1.18+ behaviour; structure follows misode/deepslate's NoiseAquifer, MIT, with Java 26.3's semantics where deepslate 0.27.2 differs: both section offsets when sampling the surface, floorDiv(z, 16) and the x10 spread for fluid level cells).
Java 26.3 details checked against a real server: aquifer centers are spread by nextInt(10), nextInt(9), nextInt(10); the center column is sampled first when looking for the surface; a center at the same distance as a previous one takes its place in the nearest-three ordering; the density samplers return floats (so every noise value read here is rounded to single precision, and the spread is multiplied by 10 in single precision), while the similarity and barrier pressure math is done in double precision.
Materials are the MATERIAL_* constants; -1 means "keep the default block" (stone).
Constants
MATERIAL_AIR
public const MATERIAL_AIR = 0MATERIAL_LAVA
public const MATERIAL_LAVA = 3MATERIAL_STONE
public const MATERIAL_STONE = 1MATERIAL_WATER
public const MATERIAL_WATER = 2Methods
__construct()
public function __construct(\pocketmine\world\generator\vanilla\NoiseRouter $router, \pocketmine\world\generator\vanilla\random\PositionalRandomFactory $random, int $chunkX, int $chunkZ, \pocketmine\world\generator\vanilla\density\DensityFunction $barrier, \pocketmine\world\generator\vanilla\density\DensityFunction $floodedness, \pocketmine\world\generator\vanilla\density\DensityFunction $spread, …computeSubstance()
public function computeSubstance(int $x, int $y, int $z, float $density) : intReturns one of the MATERIAL_* constants, or -1 when the block stays solid (default block).
floorDiv()
public static function floorDiv(int $a, int $b) : intgetSkipSamplingAboveY()
public function getSkipSamplingAboveY() : int