Further cleanup to general AABB handling

This commit is contained in:
Dylan K. Taylor
2018-11-24 19:17:03 +00:00
parent d5ae4ad141
commit b2201c8c59
25 changed files with 36 additions and 58 deletions

View File

@ -60,8 +60,7 @@ class FlowerPot extends Flowable{
}
protected function recalculateBoundingBox() : ?AxisAlignedBB{
static $f = 0.3125;
return new AxisAlignedBB($f, 0, $f, 1 - $f, 0.375, 1 - $f);
return AxisAlignedBB::one()->contract(3 / 16, 0, 3 / 16)->trim(Facing::UP, 5 / 8);
}
public function place(Item $item, Block $blockReplace, Block $blockClicked, int $face, Vector3 $clickVector, Player $player = null) : bool{