Some packets

This commit is contained in:
Shoghi Cervantes Pueyo
2012-10-19 05:07:20 +02:00
parent 22965e0acf
commit 123f988017
4 changed files with 35 additions and 40 deletions

View File

@ -71,8 +71,11 @@ class MinecraftInterface{
if($data[3] === false){
return false;
}
$pid = $data[0]{0};
$pid = ord($pid);
$pid = ord($data[0]);
if($pid === 0x84){
$data[0] = substr($data[0], 10);
$pid = ord($data[0]);
}
$struct = $this->getStruct($pid);
if($struct === false){
$p = "[".microtime(true)."] [SERVER->CLIENT]: Error, bad packet id 0x".Utils::strToHex(chr($pid)).PHP_EOL;