From 287f08cbd1f9a5a2fbbbe920d4cec548eb544dc0 Mon Sep 17 00:00:00 2001 From: "Dylan K. Taylor" Date: Tue, 10 Oct 2017 21:56:17 +0100 Subject: [PATCH] Changed confusing MovePlayerPacket field name to be consistent with other packets --- src/pocketmine/Player.php | 2 +- .../network/mcpe/protocol/MovePlayerPacket.php | 12 ++++++------ 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/src/pocketmine/Player.php b/src/pocketmine/Player.php index 0fca702603..5e7b9dd506 100644 --- a/src/pocketmine/Player.php +++ b/src/pocketmine/Player.php @@ -3631,8 +3631,8 @@ class Player extends Human implements CommandSender, ChunkLoader, IPlayer{ $pk = new MovePlayerPacket(); $pk->entityRuntimeId = $this->getId(); $pk->position = $this->getOffsetPosition($pos); - $pk->bodyYaw = $yaw; $pk->pitch = $pitch; + $pk->headYaw = $yaw; $pk->yaw = $yaw; $pk->mode = $mode; diff --git a/src/pocketmine/network/mcpe/protocol/MovePlayerPacket.php b/src/pocketmine/network/mcpe/protocol/MovePlayerPacket.php index 3d51755f28..371c2936d4 100644 --- a/src/pocketmine/network/mcpe/protocol/MovePlayerPacket.php +++ b/src/pocketmine/network/mcpe/protocol/MovePlayerPacket.php @@ -42,11 +42,11 @@ class MovePlayerPacket extends DataPacket{ /** @var Vector3 */ public $position; /** @var float */ - public $yaw; - /** @var float */ - public $bodyYaw; - /** @var float */ public $pitch; + /** @var float */ + public $headYaw; + /** @var float */ + public $yaw; /** @var int */ public $mode = self::MODE_NORMAL; /** @var bool */ @@ -62,8 +62,8 @@ class MovePlayerPacket extends DataPacket{ $this->entityRuntimeId = $this->getEntityRuntimeId(); $this->position = $this->getVector3Obj(); $this->pitch = $this->getLFloat(); + $this->headYaw = $this->getLFloat(); $this->yaw = $this->getLFloat(); - $this->bodyYaw = $this->getLFloat(); $this->mode = $this->getByte(); $this->onGround = $this->getBool(); $this->ridingEid = $this->getEntityRuntimeId(); @@ -77,8 +77,8 @@ class MovePlayerPacket extends DataPacket{ $this->putEntityRuntimeId($this->entityRuntimeId); $this->putVector3Obj($this->position); $this->putLFloat($this->pitch); + $this->putLFloat($this->headYaw); //TODO $this->putLFloat($this->yaw); - $this->putLFloat($this->bodyYaw); //TODO $this->putByte($this->mode); $this->putBool($this->onGround); $this->putEntityRuntimeId($this->ridingEid);