mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-05-10 15:59:39 +00:00
PopulationTask: do not calculate lighting for chunks
we do this ondemand now, which means this is just wasting CPU for the vast majority of generated chunks.
This commit is contained in:
parent
31c2c3abb5
commit
05ab75b5ce
@ -23,7 +23,6 @@ declare(strict_types=1);
|
||||
|
||||
namespace pocketmine\world\generator;
|
||||
|
||||
use pocketmine\block\BlockFactory;
|
||||
use pocketmine\scheduler\AsyncTask;
|
||||
use pocketmine\world\format\Chunk;
|
||||
use pocketmine\world\format\io\FastChunkSerializer;
|
||||
@ -118,11 +117,6 @@ class PopulationTask extends AsyncTask{
|
||||
$chunk = $manager->getChunk($chunk->getX(), $chunk->getZ());
|
||||
$chunk->setPopulated();
|
||||
|
||||
$blockFactory = BlockFactory::getInstance();
|
||||
$chunk->recalculateHeightMap($blockFactory->blocksDirectSkyLight);
|
||||
$chunk->populateSkyLight($blockFactory->lightFilter);
|
||||
$chunk->setLightPopulated();
|
||||
|
||||
$this->chunk = FastChunkSerializer::serialize($chunk);
|
||||
|
||||
foreach($chunks as $i => $c){
|
||||
|
Loading…
x
Reference in New Issue
Block a user