should have fixed spawn

This commit is contained in:
GameHerobrine 2023-07-08 22:06:58 +03:00
parent 28c0541164
commit 5b2c7bc9d0
3 changed files with 28 additions and 17 deletions

View file

@ -38,6 +38,7 @@ class MobSpawner{
}else{
return false;
}
if(empty($this->level->usedChunks)) return false;
$chunk = explode(".", array_rand($this->level->usedChunks, 1));
$x = $chunk[0] * 16;
$z = $chunk[1] * 16;