CreativeInventory per Player (#5694)

This commit is contained in:
BrandPVP
2023-07-06 13:08:13 +03:00
committed by GitHub
parent 8f217ca6e0
commit c01d2dc718
4 changed files with 25 additions and 6 deletions

View File

@ -35,7 +35,6 @@ use pocketmine\block\inventory\LoomInventory;
use pocketmine\block\inventory\SmithingTableInventory;
use pocketmine\block\inventory\StonecutterInventory;
use pocketmine\crafting\FurnaceType;
use pocketmine\inventory\CreativeInventory;
use pocketmine\inventory\Inventory;
use pocketmine\inventory\transaction\action\SlotChangeAction;
use pocketmine\inventory\transaction\InventoryTransaction;
@ -603,7 +602,7 @@ class InventoryManager{
}
public function syncCreative() : void{
$this->session->sendDataPacket(CreativeInventoryCache::getInstance()->getCache(CreativeInventory::getInstance()));
$this->session->sendDataPacket(CreativeInventoryCache::getInstance()->getCache($this->player->getCreativeInventory()));
}
private function newItemStackId() : int{