mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-09-04 17:06:16 +00:00
DataPacket: inject buffer via parameter instead of class field (packet & stream separation, step 2)
this is not complete yet, but the final change (having the binarystream actually come from outside) is a little more disruptive, and some extra changes need to be made. This will grant some sanity in the meantime without breaking too much stuff.
This commit is contained in:
@ -24,15 +24,16 @@ declare(strict_types=1);
|
||||
namespace pocketmine\network\mcpe\protocol;
|
||||
|
||||
use pocketmine\network\mcpe\handler\PacketHandler;
|
||||
use pocketmine\network\mcpe\serializer\NetworkBinaryStream;
|
||||
|
||||
class TestPacket extends DataPacket{
|
||||
public const NETWORK_ID = 1023;
|
||||
|
||||
protected function decodePayload() : void{
|
||||
protected function decodePayload(NetworkBinaryStream $in) : void{
|
||||
|
||||
}
|
||||
|
||||
protected function encodePayload() : void{
|
||||
protected function encodePayload(NetworkBinaryStream $out) : void{
|
||||
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user