diff --git a/src/Player.php b/src/Player.php index 87572c40e..c8c19b930 100644 --- a/src/Player.php +++ b/src/Player.php @@ -218,8 +218,8 @@ class Player{ } } $pk = new ChunkDataPacket; - $pk->x = $X; - $pk->z = $Z; + $pk->chunkX = $X; + $pk->chunkZ = $Z; $pk->data = $this->level->getOrderedChunk($X, $Z, $Yndex); $cnt = $this->dataPacket($pk); if($cnt === false){ diff --git a/src/network/protocol/packet/ChunkDataPacket.php b/src/network/protocol/packet/ChunkDataPacket.php index 0546f55f8..05ccb67f1 100644 --- a/src/network/protocol/packet/ChunkDataPacket.php +++ b/src/network/protocol/packet/ChunkDataPacket.php @@ -20,8 +20,8 @@ */ class ChunkDataPacket extends RakNetDataPacket{ - public $x; - public $z; + public $chunkX; + public $chunkZ; public $data; public function pid(){ @@ -34,8 +34,8 @@ class ChunkDataPacket extends RakNetDataPacket{ public function encode(){ $this->reset(); - $this->putInt($this->x); - $this->putInt($this->z); + $this->putInt($this->chunkX); + $this->putInt($this->chunkZ); $this->put($this->data); } diff --git a/src/network/protocol/packet/RequestChunkPacket.php b/src/network/protocol/packet/RequestChunkPacket.php index 8629e0519..f3f3b604c 100644 --- a/src/network/protocol/packet/RequestChunkPacket.php +++ b/src/network/protocol/packet/RequestChunkPacket.php @@ -20,16 +20,16 @@ */ class RequestChunkPacket extends RakNetDataPacket{ - public $x; - public $z; + public $chunkX; + public $chunkZ; public function pid(){ return ProtocolInfo::REQUEST_CHUNK_PACKET; } public function decode(){ - $this->x = $this->getInt(); - $this->z = $this->getInt(); + $this->chunkX = $this->getInt(); + $this->chunkZ = $this->getInt(); } public function encode(){