mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-09-08 02:42:58 +00:00
Cleaned up some bad code in DataPacket, added encode/decodeHeader and made encode/decodePayload protected
This commit is contained in:
@ -59,7 +59,7 @@ class InteractPacket extends DataPacket{
|
||||
/** @var float */
|
||||
public $z;
|
||||
|
||||
public function decodePayload(){
|
||||
protected function decodePayload(){
|
||||
$this->action = $this->getByte();
|
||||
$this->target = $this->getEntityRuntimeId();
|
||||
|
||||
@ -70,7 +70,7 @@ class InteractPacket extends DataPacket{
|
||||
}
|
||||
}
|
||||
|
||||
public function encodePayload(){
|
||||
protected function encodePayload(){
|
||||
$this->putByte($this->action);
|
||||
$this->putEntityRuntimeId($this->target);
|
||||
|
||||
|
Reference in New Issue
Block a user