mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-09-06 09:56:06 +00:00
Merge branch 'master' into mcpe-1.2
This commit is contained in:
@ -48,13 +48,16 @@ class CraftingDataPacket extends DataPacket{
|
||||
/** @var bool */
|
||||
public $cleanRecipes = false;
|
||||
|
||||
public $decodedEntries = [];
|
||||
|
||||
public function clean(){
|
||||
$this->entries = [];
|
||||
$this->decodedEntries = [];
|
||||
return parent::clean();
|
||||
}
|
||||
|
||||
protected function decodePayload(){
|
||||
$entries = [];
|
||||
$this->decodedEntries = [];
|
||||
$recipeCount = $this->getUnsignedVarInt();
|
||||
for($i = 0; $i < $recipeCount; ++$i){
|
||||
$entry = [];
|
||||
@ -106,7 +109,7 @@ class CraftingDataPacket extends DataPacket{
|
||||
default:
|
||||
throw new \UnexpectedValueException("Unhandled recipe type $recipeType!"); //do not continue attempting to decode
|
||||
}
|
||||
$entries[] = $entry;
|
||||
$this->decodedEntries[] = $entry;
|
||||
}
|
||||
$this->getBool(); //cleanRecipes
|
||||
}
|
||||
|
Reference in New Issue
Block a user