Disconnect 1.1 clients properly (HACK!)

This commit is contained in:
Dylan K. Taylor
2017-09-26 10:01:32 +01:00
parent ccbdb77618
commit e64076ec81
3 changed files with 24 additions and 0 deletions

View File

@ -72,6 +72,10 @@ class LoginPacket extends DataPacket{
$this->protocol = $this->getInt();
if($this->protocol !== ProtocolInfo::CURRENT_PROTOCOL){
if($this->protocol > 0xffff){ //guess MCPE <= 1.1
$this->offset -= 6;
$this->protocol = $this->getInt();
}
return; //Do not attempt to continue decoding for non-accepted protocols
}