1.11.0 protocol changes

This commit is contained in:
Dylan K. Taylor
2019-04-24 19:54:16 +01:00
parent fc76d04dcb
commit fa70127241
16 changed files with 271 additions and 99 deletions

View File

@ -33,6 +33,8 @@ class LecternUpdatePacket extends DataPacket/* implements ServerboundPacket*/{
/** @var int */
public $page;
/** @var int */
public $totalPages;
/** @var int */
public $x;
/** @var int */
public $y;
@ -43,12 +45,14 @@ class LecternUpdatePacket extends DataPacket/* implements ServerboundPacket*/{
protected function decodePayload() : void{
$this->page = $this->getByte();
$this->totalPages = $this->getByte();
$this->getBlockPosition($this->x, $this->y, $this->z);
$this->dropBook = $this->getBool();
}
protected function encodePayload() : void{
$this->putByte($this->page);
$this->putByte($this->totalPages);
$this->putBlockPosition($this->x, $this->y, $this->z);
$this->putBool($this->dropBook);
}