This commit is contained in:
GameHerobrine 2023-07-03 07:54:57 +03:00
parent c12f48b84b
commit 457eee1157
5 changed files with 15 additions and 15 deletions

View file

@ -87,11 +87,11 @@ class ExperimentalGenerator implements NewLevelGenerator{
$this->populators[] = $tallGrass;
}
public function pickBiome($x, $z){
$hash = (int) ($x * 2345803 ^ $z * 9236449 ^ $this->level->level->getSeed());
public function pickBiome(int $x, int $z){
$hash = $x * 2345803 ^ $z * 9236449 ^ $this->level->level->getSeed();
$hash *= $hash + 223;
$xNoise = ((int)$hash) >> 20 & 3;
$zNoise = ((int)$hash) >> 22 & 3;
$xNoise = $hash >> 20 & 3;
$zNoise = $hash >> 22 & 3;
if($xNoise == 3){
$xNoise = 1;
}