fixed yaw/headyaw field order

I wish they'd stop changing this shit... this is the third or fourth time now?
This commit is contained in:
Dylan K. Taylor 2017-10-10 22:45:30 +01:00
parent 287f08cbd1
commit 2a5d954c67
2 changed files with 8 additions and 8 deletions

View File

@ -48,10 +48,10 @@ class AddPlayerPacket extends DataPacket{
public $motion; public $motion;
/** @var float */ /** @var float */
public $pitch = 0.0; public $pitch = 0.0;
/** @var float|null */
public $headYaw = null; //TODO
/** @var float */ /** @var float */
public $yaw = 0.0; public $yaw = 0.0;
/** @var float|null */
public $headYaw = null; //TODO
/** @var Item */ /** @var Item */
public $item; public $item;
/** @var array */ /** @var array */
@ -77,8 +77,8 @@ class AddPlayerPacket extends DataPacket{
$this->position = $this->getVector3Obj(); $this->position = $this->getVector3Obj();
$this->motion = $this->getVector3Obj(); $this->motion = $this->getVector3Obj();
$this->pitch = $this->getLFloat(); $this->pitch = $this->getLFloat();
$this->headYaw = $this->getLFloat();
$this->yaw = $this->getLFloat(); $this->yaw = $this->getLFloat();
$this->headYaw = $this->getLFloat();
$this->item = $this->getSlot(); $this->item = $this->getSlot();
$this->metadata = $this->getEntityMetadata(); $this->metadata = $this->getEntityMetadata();
@ -104,8 +104,8 @@ class AddPlayerPacket extends DataPacket{
$this->putVector3Obj($this->position); $this->putVector3Obj($this->position);
$this->putVector3ObjNullable($this->motion); $this->putVector3ObjNullable($this->motion);
$this->putLFloat($this->pitch); $this->putLFloat($this->pitch);
$this->putLFloat($this->headYaw ?? $this->yaw);
$this->putLFloat($this->yaw); $this->putLFloat($this->yaw);
$this->putLFloat($this->headYaw ?? $this->yaw);
$this->putSlot($this->item); $this->putSlot($this->item);
$this->putEntityMetadata($this->metadata); $this->putEntityMetadata($this->metadata);

View File

@ -44,9 +44,9 @@ class MovePlayerPacket extends DataPacket{
/** @var float */ /** @var float */
public $pitch; public $pitch;
/** @var float */ /** @var float */
public $headYaw;
/** @var float */
public $yaw; public $yaw;
/** @var float */
public $headYaw;
/** @var int */ /** @var int */
public $mode = self::MODE_NORMAL; public $mode = self::MODE_NORMAL;
/** @var bool */ /** @var bool */
@ -62,8 +62,8 @@ class MovePlayerPacket extends DataPacket{
$this->entityRuntimeId = $this->getEntityRuntimeId(); $this->entityRuntimeId = $this->getEntityRuntimeId();
$this->position = $this->getVector3Obj(); $this->position = $this->getVector3Obj();
$this->pitch = $this->getLFloat(); $this->pitch = $this->getLFloat();
$this->headYaw = $this->getLFloat();
$this->yaw = $this->getLFloat(); $this->yaw = $this->getLFloat();
$this->headYaw = $this->getLFloat();
$this->mode = $this->getByte(); $this->mode = $this->getByte();
$this->onGround = $this->getBool(); $this->onGround = $this->getBool();
$this->ridingEid = $this->getEntityRuntimeId(); $this->ridingEid = $this->getEntityRuntimeId();
@ -77,8 +77,8 @@ class MovePlayerPacket extends DataPacket{
$this->putEntityRuntimeId($this->entityRuntimeId); $this->putEntityRuntimeId($this->entityRuntimeId);
$this->putVector3Obj($this->position); $this->putVector3Obj($this->position);
$this->putLFloat($this->pitch); $this->putLFloat($this->pitch);
$this->putLFloat($this->headYaw); //TODO
$this->putLFloat($this->yaw); $this->putLFloat($this->yaw);
$this->putLFloat($this->headYaw); //TODO
$this->putByte($this->mode); $this->putByte($this->mode);
$this->putBool($this->onGround); $this->putBool($this->onGround);
$this->putEntityRuntimeId($this->ridingEid); $this->putEntityRuntimeId($this->ridingEid);