This commit is contained in:
GameHerobrine 2023-08-30 08:20:43 +03:00
parent b10963746e
commit 5799426f1b
3 changed files with 6 additions and 5 deletions

View file

@ -148,7 +148,8 @@ class PluginAPI extends stdClass{
$aver = CURRENT_API_VERSION;
if(!in_array((string) CURRENT_API_VERSION, $pluginInfo["api"])){
console("[WARNING] API is not the same as Core, might cause bugs({$pluginInfo["api"]} != {$aver})");
$s = implode(", ", $pluginInfo["api"]);
console("[WARNING] API is not the same as Core, might cause bugs({$s} != {$aver})");
}
$phr = "phar://$filePath/";

View file

@ -477,7 +477,7 @@ class Level{
return false;
}
$this->changedCount[$X . ":" . $Y . ":" . $Z] = 4096;
if(ADVANCED_CACHE == true){
if(ADVANCED_CACHE){
Cache::remove("world:{$this->name}:$X:$Z");
}
return $this->level->setMiniChunk($X, $Z, $Y, $data);

View file

@ -103,11 +103,9 @@ class ExperimentalGenerator implements NewLevelGenerator{
public function generateChunk($chunkX, $chunkZ){
$this->random->setSeed(0xdeadbeef ^ ($chunkX << 8) ^ $chunkZ ^ $this->level->level->getSeed());
$noiseArray = ExperimentalGenerator::getFastNoise3D($this->noiseBase, 16, 128, 16, 4, 8, 4, $chunkX * 16, 0, $chunkZ * 16);
$biomeCache = [];
$t = microtime(1);
for($chunkY = 0; $chunkY < 8; ++$chunkY){
$chunk = "";
$startY = $chunkY << 4;
@ -164,6 +162,8 @@ class ExperimentalGenerator implements NewLevelGenerator{
}
$this->level->setMiniChunk($chunkX, $chunkZ, $chunkY, $chunk);
}
$t = microtime(1) - $t;
console("gen:".$t);
foreach($this->genPopulators as $pop){