Found an unknown field in ChangeDimensionPacket

No idea what this is actually used for though. It's set when a client dies in a different dimension and respawns in the overworld.
This commit is contained in:
Dylan K. Taylor 2017-06-22 15:51:56 +01:00
parent 6a2a74a457
commit 89ca2ac2d5

View File

@ -38,19 +38,19 @@ class ChangeDimensionPacket extends DataPacket{
public $x;
public $y;
public $z;
public $unknown; //bool
public $respawn = false;
public function decode(){
$this->dimension = $this->getVarInt();
$this->getVector3f($this->x, $this->y, $this->z);
$this->unknown = $this->getBool();
$this->respawn = $this->getBool();
}
public function encode(){
$this->reset();
$this->putVarInt($this->dimension);
$this->putVector3f($this->x, $this->y, $this->z);
$this->putBool($this->unknown);
$this->putBool($this->respawn);
}
public function handle(NetworkSession $session) : bool{