unloadchunkpacket

This commit is contained in:
GameHerobrine 2023-02-24 20:03:50 +03:00
parent d66ee05ae3
commit 034a45c25f
2 changed files with 29 additions and 1 deletions

View file

@ -72,7 +72,7 @@ abstract class ProtocolInfo{
const ENTITY_DATA_PACKET = 0xb8;
const PLAYER_INPUT_PACKET = 0xb9;
const FULL_CHUNK_DATA_PACKET = 0xba;
//const UNLOAD_CHUNK_PACKET = 0xbb;
const UNLOAD_CHUNK_PACKET = 0xbb;
}
/*Unused:

View file

@ -0,0 +1,28 @@
<?php
class UnloadChunkPacket extends RakNetDataPacket
{
public $chunkX, $chunkZ;
public function __construct($chunkX = 0, $chunkZ = 0){
$this->chunkX = $chunkX;
$this->chunkZ = $chunkZ;
}
public function encode()
{
$this->reset();
$this->putInt($this->chunkX);
$this->putInt($this->chunkZ);
}
public function pid()
{
return ProtocolInfo::UNLOAD_CHUNK_PACKET;
}
public function decode()
{}
}