fixed entities falling through the ground

This commit is contained in:
GameHerobrine 2024-01-12 04:59:29 +03:00
parent 403eb71aa6
commit bf1169b3f2
7 changed files with 66 additions and 38 deletions

View file

@ -15,6 +15,11 @@ class LeavesBlock extends TransparentBlock{
$this->name = $names[$this->meta & 0x03];
$this->hardness = 1;
}
public static function getCollisionBoundingBoxes(Level $level, $x, $y, $z, Entity $entity){
return [new AxisAlignedBB($x, $y, $z, $x + 1, $y + 1, $z + 1)];
}
public static function createIndex($x, $y, $z){
return $x.".".$y.".".$z;
}