class LoginPacket extends DataPacket{ public static $pool = []; public static $next = 0; public $username; public $protocol1; public $protocol2; public $clientId; public $slim = false; public $skin = null; public function pid(){ return Info::LOGIN_PACKET; } public function decode(){ $this->username = $this->getString(); $this->protocol1 = $this->getInt(); $this->protocol2 = $this->getInt(); if(Info::CURRENT_PROTOCOL != $this->protocol1){ return; } $this->clientId = $this->getInt(); $this->slim = $this->getByte() > 0; $this->skin = $this->getString(); } public function encode(){ } }