mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-09-07 18:32:55 +00:00
oops
This commit is contained in:
@ -730,7 +730,7 @@ class InventoryManager implements InventoryListener{
|
||||
$playerInventory = $this->player->getInventory();
|
||||
$selected = $this->player->getHotbar()->getSelectedIndex();
|
||||
if($selected !== $this->clientSelectedHotbarSlot){
|
||||
$inventoryEntry = $this->getEntryByWindow($this->getInventoryWindow($playerInventory)) ?? throw new AssumptionFailedError("Player inventory should always be tracked");
|
||||
$inventoryEntry = $this->getEntry($playerInventory) ?? throw new AssumptionFailedError("Player inventory should always be tracked");
|
||||
$itemStackInfo = $inventoryEntry->itemStackInfos[$selected] ?? null;
|
||||
if($itemStackInfo === null){
|
||||
throw new AssumptionFailedError("Untracked player inventory slot $selected");
|
||||
|
Reference in New Issue
Block a user