mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-04-23 00:55:57 +00:00
GroundCover: don't replace liquid with can-be-flowed-into blocks
fixes snow layers generating underwater
This commit is contained in:
parent
78ec3937bf
commit
8cd311bcb4
@ -24,6 +24,7 @@ declare(strict_types=1);
|
||||
namespace pocketmine\level\generator\populator;
|
||||
|
||||
use pocketmine\block\BlockFactory;
|
||||
use pocketmine\block\Liquid;
|
||||
use pocketmine\level\biome\Biome;
|
||||
use pocketmine\level\ChunkManager;
|
||||
use pocketmine\utils\Random;
|
||||
@ -55,6 +56,9 @@ class GroundCover extends Populator{
|
||||
if($column{$y} === "\x00" and $b->isSolid()){
|
||||
break;
|
||||
}
|
||||
if($b->canBeFlowedInto() and BlockFactory::get(ord($column{$y})) instanceof Liquid){
|
||||
continue;
|
||||
}
|
||||
if($b->getDamage() === 0){
|
||||
$chunk->setBlockId($x, $y, $z, $b->getId());
|
||||
}else{
|
||||
|
Loading…
x
Reference in New Issue
Block a user