We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 9f5ced2 commit b1b0a64Copy full SHA for b1b0a64
src/entity/Entity.php
@@ -660,7 +660,13 @@ protected function entityBaseTick(int $tickDiff = 1) : bool{
660
$hasUpdate = true;
661
}elseif($this->isOnGround()){
662
$block = $this->getWorld()->getBlock($this->getLocation()->subtract(0, 1, 0));
663
- $block->onEntityCollide($this);
+ $entityBox = $this->getBoundingBox()->addCoord(0, -0.00001, 0);
664
+ foreach ($block->getCollisionBoxes() as $blockBox) {
665
+ if ($entityBox->intersectsWith($blockBox)) {
666
+ $block->onEntityCollide($this);
667
+ break;
668
+ }
669
670
}
671
672
if($this->isOnFire() && $this->doOnFireTick($tickDiff)){
0 commit comments