mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-09-06 01:46:04 +00:00
Cleaned up muddled varint/varlong mess, added separate methods for entity unique and runtime ids, moved some MCPE-protocol-specific methods out of BinaryStream
This commit is contained in:
@ -44,7 +44,7 @@ class MovePlayerPacket extends DataPacket{
|
||||
public $onGround;
|
||||
|
||||
public function decode(){
|
||||
$this->eid = $this->getEntityId(); //EntityRuntimeID
|
||||
$this->eid = $this->getEntityRuntimeId();
|
||||
$this->getVector3f($this->x, $this->y, $this->z);
|
||||
$this->pitch = $this->getLFloat();
|
||||
$this->yaw = $this->getLFloat();
|
||||
@ -55,7 +55,7 @@ class MovePlayerPacket extends DataPacket{
|
||||
|
||||
public function encode(){
|
||||
$this->reset();
|
||||
$this->putEntityId($this->eid); //EntityRuntimeID
|
||||
$this->putEntityRuntimeId($this->eid);
|
||||
$this->putVector3f($this->x, $this->y, $this->z);
|
||||
$this->putLFloat($this->pitch);
|
||||
$this->putLFloat($this->yaw);
|
||||
|
Reference in New Issue
Block a user