Removed handler for PlayerHotbarPacket

this thing is useless now, and the equipment stuff can be done with MobEquipmentPacket anyway.
This commit is contained in:
Dylan K. Taylor 2017-11-18 16:03:18 +00:00
parent dc553142c9
commit dd8a772d43
2 changed files with 1 additions and 11 deletions

View File

@ -2807,16 +2807,6 @@ class Player extends Human implements CommandSender, ChunkLoader, IPlayer{
return false;
}
public function handlePlayerHotbar(PlayerHotbarPacket $packet){
if($packet->windowId !== ContainerIds::INVENTORY){
return false; //In PE this should never happen
}
$this->inventory->equipItem($packet->selectedHotbarSlot);
return true;
}
public function handleAdventureSettings(AdventureSettingsPacket $packet) : bool{
if($packet->entityUniqueId !== $this->getId()){
return false; //TODO

View File

@ -169,7 +169,7 @@ class PlayerNetworkSessionAdapter extends NetworkSession{
}
public function handlePlayerHotbar(PlayerHotbarPacket $packet) : bool{
return $this->player->handlePlayerHotbar($packet);
return true; //this packet is useless
}
public function handleCraftingEvent(CraftingEventPacket $packet) : bool{