mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-04-22 16:51:42 +00:00
populate missing array value types in level namespace
This commit is contained in:
parent
8bf469f7fc
commit
a5764b3ae9
@ -1137,6 +1137,9 @@ class Level implements ChunkManager, Metadatable{
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @return mixed[]
|
||||
*/
|
||||
public function __debugInfo() : array{
|
||||
return [];
|
||||
}
|
||||
|
@ -53,6 +53,8 @@ interface LevelProvider{
|
||||
/**
|
||||
* Generate the needed files in the path given
|
||||
*
|
||||
* @param mixed[] $options
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public static function generate(string $path, string $name, int $seed, string $generator, array $options = []);
|
||||
@ -62,6 +64,9 @@ interface LevelProvider{
|
||||
*/
|
||||
public function getGenerator() : string;
|
||||
|
||||
/**
|
||||
* @return mixed[]
|
||||
*/
|
||||
public function getGeneratorOptions() : array;
|
||||
|
||||
/**
|
||||
|
@ -64,6 +64,8 @@ class Flat extends Generator{
|
||||
}
|
||||
|
||||
/**
|
||||
* @param mixed[] $options
|
||||
*
|
||||
* @throws InvalidGeneratorOptionsException
|
||||
*/
|
||||
public function __construct(array $options = []){
|
||||
|
@ -56,6 +56,8 @@ abstract class Generator{
|
||||
|
||||
/**
|
||||
* @throws InvalidGeneratorOptionsException
|
||||
*
|
||||
* @param mixed[] $settings
|
||||
*/
|
||||
abstract public function __construct(array $settings = []);
|
||||
|
||||
@ -68,6 +70,9 @@ abstract class Generator{
|
||||
|
||||
abstract public function populateChunk(int $chunkX, int $chunkZ) : void;
|
||||
|
||||
/**
|
||||
* @return mixed[]
|
||||
*/
|
||||
abstract public function getSettings() : array;
|
||||
|
||||
abstract public function getName() : string;
|
||||
|
@ -45,6 +45,9 @@ class GeneratorRegisterTask extends AsyncTask{
|
||||
/** @var int */
|
||||
public $worldHeight = Level::Y_MAX;
|
||||
|
||||
/**
|
||||
* @param mixed[] $generatorSettings
|
||||
*/
|
||||
public function __construct(Level $level, string $generatorClass, array $generatorSettings = []){
|
||||
$this->generatorClass = $generatorClass;
|
||||
$this->settings = serialize($generatorSettings);
|
||||
|
@ -53,6 +53,8 @@ class Nether extends Generator{
|
||||
private $noiseBase;
|
||||
|
||||
/**
|
||||
* @param mixed[] $options
|
||||
*
|
||||
* @throws InvalidGeneratorOptionsException
|
||||
*/
|
||||
public function __construct(array $options = []){
|
||||
|
@ -307,6 +307,9 @@ abstract class Noise{
|
||||
return $noiseArray;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return float[][][]
|
||||
*/
|
||||
public function getFastNoise3D(int $xSize, int $ySize, int $zSize, int $xSamplingRate, int $ySamplingRate, int $zSamplingRate, int $x, int $y, int $z) : array{
|
||||
|
||||
assert($xSamplingRate !== 0, new \InvalidArgumentException("xSamplingRate cannot be 0"));
|
||||
|
@ -61,6 +61,8 @@ class Normal extends Generator{
|
||||
private static $SMOOTH_SIZE = 2;
|
||||
|
||||
/**
|
||||
* @param mixed[] $options
|
||||
*
|
||||
* @throws InvalidGeneratorOptionsException
|
||||
*/
|
||||
public function __construct(array $options = []){
|
||||
|
Loading…
x
Reference in New Issue
Block a user