mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-05-16 02:38:54 +00:00
Added RotateHeadPacket
This commit is contained in:
parent
de5e9df82b
commit
c2d760e6d9
@ -1283,6 +1283,7 @@ class Player extends Human implements CommandSender, InventoryHolder, IPlayer{
|
||||
$this->server->getLogger()->warning($this->username." moved too quickly!");
|
||||
}
|
||||
}else{*/
|
||||
|
||||
if(!$this->setPositionAndRotation($newPos, $packet->yaw, $packet->pitch)){
|
||||
$pk = new MovePlayerPacket();
|
||||
$pk->eid = 0;
|
||||
|
@ -37,7 +37,7 @@ class RotateHeadPacket extends DataPacket{
|
||||
public function encode(){
|
||||
$this->reset();
|
||||
$this->putInt($this->eid);
|
||||
$this->putByte($this->yaw);
|
||||
$this->putByte((int) ($this->yaw / 360));
|
||||
}
|
||||
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user