PHP: $item = $item->setCustomName(TF::RESET . " §6Wallet \n §eMoney: $money "); if($level !== null) { $level->dropItem(new Vector3(145, 63, 178, $item)); } This gives me error that it should be instance of pocketmine/item/Item, null given; but then how do i setCustomName() for that item?
Could not execute Task, Argument 2 passed to pocketmine\level\Level::dropitem() must be an instance of pocketmine\item\Item, none given
PHP: $item = Item::get(339, 0, 1);$item->setCustomName(TF::RESET . " §6Wallet \n §eMoney: $money ");$level = $player->getLevel()->getName();$level->dropItem(new Vector3(145, 63, 178, $item)); Seems like it.