mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-04-21 00:07:30 +00:00
Level: Removed fire hack from destroyBlockInternal()
this was causing unexpected behaviour particularly on burning trees, whereby fire would be unconditionally extinguished if the block below it was removed.
This commit is contained in:
parent
691df5c11d
commit
f47f593555
@ -1735,11 +1735,6 @@ class Level implements ChunkManager, Metadatable{
|
||||
}
|
||||
|
||||
private function destroyBlockInternal(Block $target, Item $item, ?Player $player = null, bool $createParticles = false) : void{
|
||||
$above = $this->getBlockAt($target->x, $target->y + 1, $target->z);
|
||||
if($above->getId() === Block::FIRE){ //TODO: this should be done in Fire's onUpdate(), not with this hack
|
||||
$this->setBlock($above, BlockFactory::get(Block::AIR), true);
|
||||
}
|
||||
|
||||
if($createParticles){
|
||||
$this->addParticle(new DestroyBlockParticle($target->add(0.5, 0.5, 0.5), $target));
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user