mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-09-07 18:32:55 +00:00
Inventory: Split up armor and player inventory (#1957)
* Inventory: Split up PlayerInventory and armour handling * Fixed other players don't see armour changes. This bug also exists on master.
This commit is contained in:
@ -159,12 +159,6 @@ class NetworkInventoryAction{
|
||||
public function createInventoryAction(Player $player){
|
||||
switch($this->sourceType){
|
||||
case self::SOURCE_CONTAINER:
|
||||
if($this->windowId === ContainerIds::ARMOR){
|
||||
//TODO: HACK!
|
||||
$this->inventorySlot += 36;
|
||||
$this->windowId = ContainerIds::INVENTORY;
|
||||
}
|
||||
|
||||
$window = $player->getWindow($this->windowId);
|
||||
if($window !== null){
|
||||
return new SlotChangeAction($window, $this->inventorySlot, $this->oldItem, $this->newItem);
|
||||
|
Reference in New Issue
Block a user