diff --git a/src/Ad5001/BetterGen/generator/BetterBiomeSelector.php b/src/Ad5001/BetterGen/generator/BetterBiomeSelector.php index e6e200b..7a11f2a 100644 --- a/src/Ad5001/BetterGen/generator/BetterBiomeSelector.php +++ b/src/Ad5001/BetterGen/generator/BetterBiomeSelector.php @@ -21,16 +21,16 @@ use pocketmine\utils\Random; class BetterBiomeSelector extends BiomeSelector { /** @var Biome */ - private $fallback; + protected $fallback; /** @var Simplex */ - private $temperature; + protected $temperature; /** @var Simplex */ - private $rainfall; + protected $rainfall; /** @var Biome[] */ - private $biomes = [ ]; - private $lookup; + protected $biomes = [ ]; + protected $lookup; public function __construct(Random $random, callable $lookup, Biome $fallback) { parent::__construct($random, $lookup, $fallback); $this->fallback = $fallback; diff --git a/src/Ad5001/BetterGen/generator/BetterNormal.php b/src/Ad5001/BetterGen/generator/BetterNormal.php index a0c7528..2752377 100644 --- a/src/Ad5001/BetterGen/generator/BetterNormal.php +++ b/src/Ad5001/BetterGen/generator/BetterNormal.php @@ -73,7 +73,7 @@ class BetterNormal extends Generator { public static $levels = [ ]; protected static $GAUSSIAN_KERNEL = null; // From main class protected static $SMOOTH_SIZE = 2; - protected static $options = [ + public static $options = [ "delBio" => [ ], "delStruct" => [ @@ -81,7 +81,7 @@ class BetterNormal extends Generator { ] ]; protected $waterHeight = 63; - private $noiseBase; + protected $noiseBase; /* * Picks a biome by X and Z @@ -407,7 +407,7 @@ class BetterNormal extends Generator { /* * Generates the generation kernel based on smooth size (here 2) */ - private static function generateKernel() { + protected static function generateKernel() { self::$GAUSSIAN_KERNEL = [ ]; $bellSize = 1 / self::$SMOOTH_SIZE; diff --git a/src/Ad5001/BetterGen/populator/DeadbushPopulator.php b/src/Ad5001/BetterGen/populator/DeadbushPopulator.php index a722a21..555fd06 100644 --- a/src/Ad5001/BetterGen/populator/DeadbushPopulator.php +++ b/src/Ad5001/BetterGen/populator/DeadbushPopulator.php @@ -53,7 +53,7 @@ class DeadbushPopulator extends AmountPopulator { * @param $z * @return int */ - private function getHighestWorkableBlock($x, $z){ + protected function getHighestWorkableBlock($x, $z){ for($y = Level::Y_MAX - 1; $y > 0; --$y){ $b = $this->level->getBlockIdAt($x, $y, $z); if($b === Block::DIRT or $b === Block::GRASS or $b === Block::SAND or $b === Block::SANDSTONE or $b === Block::HARDENED_CLAY or $b === Block::STAINED_HARDENED_CLAY){ diff --git a/src/Ad5001/BetterGen/populator/FallenTreePopulator.php b/src/Ad5001/BetterGen/populator/FallenTreePopulator.php index 85c4ef7..20e0947 100644 --- a/src/Ad5001/BetterGen/populator/FallenTreePopulator.php +++ b/src/Ad5001/BetterGen/populator/FallenTreePopulator.php @@ -66,7 +66,7 @@ class FallenTreePopulator extends AmountPopulator { * @param $z * @return int */ - private function getHighestWorkableBlock($x, $z){ + protected function getHighestWorkableBlock($x, $z){ for($y = Level::Y_MAX - 1; $y > 0; --$y){ $b = $this->level->getBlockIdAt($x, $y, $z); if($b === Block::DIRT or $b === Block::GRASS){ diff --git a/src/Ad5001/BetterGen/populator/FloatingIslandPopulator.php b/src/Ad5001/BetterGen/populator/FloatingIslandPopulator.php index 28795b0..21e5a9c 100644 --- a/src/Ad5001/BetterGen/populator/FloatingIslandPopulator.php +++ b/src/Ad5001/BetterGen/populator/FloatingIslandPopulator.php @@ -41,7 +41,7 @@ class FloatingIslandPopulator extends AmountPopulator { * @param $random pocketmine\utils\Random */ /** @var ChunkManager */ - private $level; + protected $level; public function populate(ChunkManager $level, $chunkX, $chunkZ, Random $random) { $this->level = $level; diff --git a/src/Ad5001/BetterGen/structure/Cactus.php b/src/Ad5001/BetterGen/structure/Cactus.php index aff98e0..c31f0d9 100644 --- a/src/Ad5001/BetterGen/structure/Cactus.php +++ b/src/Ad5001/BetterGen/structure/Cactus.php @@ -29,7 +29,7 @@ class Cactus extends Object { * @param $z int * @param $random pocketmine\utils\Random */ - private $totalHeight; + protected $totalHeight; public function canPlaceObject(ChunkManager $level, int $x, int $y, int $z, Random $random): bool { $this->totalHeight = 1 + $random->nextBoundedInt(3); diff --git a/src/Ad5001/BetterGen/structure/FallenTree.php b/src/Ad5001/BetterGen/structure/FallenTree.php index f8bf99b..1f84ab9 100644 --- a/src/Ad5001/BetterGen/structure/FallenTree.php +++ b/src/Ad5001/BetterGen/structure/FallenTree.php @@ -39,7 +39,7 @@ class FallenTree extends Object { protected $tree; protected $direction; protected $random; - private $length = 0; + protected $length = 0; /* * Constructs the class diff --git a/src/Ad5001/BetterGen/structure/SugarCane.php b/src/Ad5001/BetterGen/structure/SugarCane.php index 8720639..33d7210 100644 --- a/src/Ad5001/BetterGen/structure/SugarCane.php +++ b/src/Ad5001/BetterGen/structure/SugarCane.php @@ -30,7 +30,7 @@ class SugarCane extends Object { * @param $z int * @param $random pocketmine\utils\Random */ - private $totalHeight; + protected $totalHeight; public function canPlaceObject(ChunkManager $level, int $x, int $y, int $z, Random $random): bool { $this->totalHeight = 1 + $random->nextBoundedInt(3); diff --git a/src/Ad5001/BetterGen/structure/Temple.php b/src/Ad5001/BetterGen/structure/Temple.php index d439bb5..35516ba 100644 --- a/src/Ad5001/BetterGen/structure/Temple.php +++ b/src/Ad5001/BetterGen/structure/Temple.php @@ -108,8 +108,8 @@ class Temple extends Object { ] ]; /** @var ChunkManager */ - private $level; - private $direction = 0; + protected $level; + protected $direction = 0; /* * Checks if a temple is placeable