mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-04-23 00:55:57 +00:00
Added End Portal frame bounding box
This commit is contained in:
parent
3bf39df255
commit
cf542ac73a
@ -21,9 +21,22 @@
|
||||
|
||||
namespace pocketmine\block;
|
||||
|
||||
use pocketmine\math\AxisAlignedBB;
|
||||
|
||||
class EndPortal extends Solid{
|
||||
public function __construct($meta = 0){
|
||||
parent::__construct(self::END_PORTAL, $meta, "End Portal");
|
||||
$this->hardness = 18000000;
|
||||
}
|
||||
|
||||
public function getBoundingBox(){
|
||||
return new AxisAlignedBB(
|
||||
$this->x,
|
||||
$this->y,
|
||||
$this->z,
|
||||
$this->x + 1,
|
||||
$this->y + (($this->getDamage() & 0x04) > 0 ? 1 : 0.8125),
|
||||
$this->z + 1
|
||||
);
|
||||
}
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user