mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-09-07 18:32:55 +00:00
Implemented concrete powder
this is a little buggy with water updating due to a hack for liquids to fix a CPU leak (210bdc2436
), but everything works fine when a block nearby gets updated.
This commit is contained in:
@ -39,7 +39,7 @@ abstract class Fallable extends Solid{
|
||||
if($type === Level::BLOCK_UPDATE_NORMAL){
|
||||
$down = $this->getSide(Vector3::SIDE_DOWN);
|
||||
if($down->getId() === self::AIR or ($down instanceof Liquid)){
|
||||
$this->level->setBlock($this, BlockFactory::get(Block::AIR), true, true);
|
||||
$this->level->setBlock($this, BlockFactory::get(Block::AIR), true);
|
||||
$fall = Entity::createEntity("FallingSand", $this->getLevel(), new CompoundTag("", [
|
||||
new ListTag("Pos", [
|
||||
new DoubleTag("", $this->x + 0.5),
|
||||
@ -63,4 +63,11 @@ abstract class Fallable extends Solid{
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @return null|Block
|
||||
*/
|
||||
public function tickFalling() : ?Block{
|
||||
return null;
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user