◆ populate()
- Parameters
-
- Returns
- mixed|void
58 $this->level = $level;
59 $amount = $random->nextRange(0, $this->randomAmount + 1) + $this->baseAmount;
60 for($i = 0; $i < $amount; ++$i){
61 $x = $random->nextRange($chunkX * 16, $chunkX * 16 + 15);
62 $z = $random->nextRange($chunkZ * 16, $chunkZ * 16 + 15);
63 $y = $this->getHighestWorkableBlock($x, $z);
65 if($y !== -1 and $this->canWaterPitStay($x, $y, $z)){
67 $this->level->setBlockDataAt($x, $y, $z, 8);
◆ setBaseAmount()
- Parameters
-
46 $this->baseAmount = $amount;
◆ setRandomAmount()
setRandomAmount |
( |
|
$amount | ) |
|
- Parameters
-
39 $this->randomAmount = $amount;
The documentation for this class was generated from the following file:
- src/pocketmine/level/generator/populator/WaterPit.php