mirror of
https://github.com/oldminecraftcommunity/NostalgiaCore.git
synced 2026-11-21 12:09:43 +00:00
fixed entity collisions with chests
This commit is contained in:
parent
a71f10294d
commit
c9da91378d
3 changed files with 7 additions and 4 deletions
|
|
@ -48,6 +48,7 @@ class StaticBlock
|
|||
self::setBlockBounds(BED_BLOCK, 0, 0, 0, 1, 0.5625, 1);
|
||||
//Cake: has bounds based on world state
|
||||
//Chest: has bounds based on world state
|
||||
self::setBlockBounds(CHEST, 0.025, 0, 0.025, 0.975, 0.95, 0.975);
|
||||
self::setBlockBounds(WHEAT_BLOCK, 0, 0, 0, 1, 0.25, 1);
|
||||
self::setBlockBounds(CARROT_BLOCK, 0, 0, 0, 1, 0.25, 1);
|
||||
self::setBlockBounds(POTATO_BLOCK,0, 0, 0, 1, 0.25, 1);
|
||||
|
|
|
|||
|
|
@ -7,6 +7,10 @@ class ChestBlock extends TransparentBlock{
|
|||
$this->isFullBlock = false;
|
||||
$this->hardness = 15;
|
||||
}
|
||||
public static function getCollisionBoundingBoxes(Level $level, $x, $y, $z, Entity $entity){
|
||||
return [new AxisAlignedBB($x + 0.025, $y, $z + 0.025, $x + 0.975, $y + 0.95, $z + 0.975)];
|
||||
}
|
||||
|
||||
public function place(Item $item, Player $player, Block $block, Block $target, $face, $fx, $fy, $fz){
|
||||
$server = ServerAPI::request();
|
||||
$faces = array(
|
||||
|
|
|
|||
|
|
@ -1,10 +1,8 @@
|
|||
<?php
|
||||
|
||||
class AnimatePacket extends RakNetDataPacket{
|
||||
/**
|
||||
* Minecart Hurt, Swing Hand
|
||||
*/
|
||||
const ANIM_1 = 0x1;
|
||||
const ANIM_SWING_HAND = 0x1;
|
||||
const ANIM_STOP_SLEEP = 0x3;
|
||||
|
||||
public $action;
|
||||
public $eid;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue