Removed crafting data cache from CraftingManager

This commit is contained in:
Dylan K. Taylor
2020-11-12 21:30:59 +00:00
parent 31089ce3b2
commit 0d9561c93f
4 changed files with 207 additions and 95 deletions

View File

@ -26,6 +26,7 @@ namespace pocketmine\network\mcpe\handler;
use pocketmine\data\bedrock\LegacyItemIdToStringIdMap;
use pocketmine\network\mcpe\convert\RuntimeBlockMapping;
use pocketmine\network\mcpe\convert\TypeConverter;
use pocketmine\network\mcpe\CraftingDataCache;
use pocketmine\network\mcpe\NetworkSession;
use pocketmine\network\mcpe\protocol\RequestChunkRadiusPacket;
use pocketmine\network\mcpe\protocol\StartGamePacket;
@ -100,7 +101,7 @@ class PreSpawnPacketHandler extends PacketHandler{
$this->session->getInvManager()->syncAll();
$this->session->getInvManager()->syncCreative();
$this->session->getInvManager()->syncSelectedHotbarSlot();
$this->session->sendDataPacket($this->server->getCraftingManager()->getCraftingDataPacket());
$this->session->sendDataPacket(CraftingDataCache::getInstance()->getCache($this->server->getCraftingManager()));
$this->session->syncPlayerList($this->server->getOnlinePlayers());
}