Merge branch 'stable' into next-minor

This commit is contained in:
Dylan K. Taylor
2022-06-24 01:32:53 +01:00
9 changed files with 34 additions and 51 deletions

View File

@@ -56,7 +56,7 @@ class Skull extends Flowable{
}
public function readStateFromData(int $id, int $stateMeta) : void{
$this->facing = $stateMeta === 1 ? Facing::UP : BlockDataSerializer::readHorizontalFacing($stateMeta);
$this->facing = ($stateMeta & 0x07) === 1 ? Facing::UP : BlockDataSerializer::readHorizontalFacing($stateMeta);
$this->noDrops = ($stateMeta & BlockLegacyMetadata::SKULL_FLAG_NO_DROPS) !== 0;
}

View File

@@ -2339,6 +2339,7 @@ class Player extends Human implements CommandSender, ChunkListener, IPlayer{
parent::syncNetworkData($properties);
$properties->setGenericFlag(EntityMetadataFlags::ACTION, $this->startAction > -1);
$properties->setGenericFlag(EntityMetadataFlags::HAS_COLLISION, $this->hasBlockCollision());
$properties->setPlayerFlag(PlayerMetadataFlags::SLEEP, $this->sleeping !== null);
$properties->setBlockPos(EntityMetadataProperties::PLAYER_BED_POSITION, $this->sleeping !== null ? BlockPosition::fromVector3($this->sleeping) : new BlockPosition(0, 0, 0));