My code gives the player items when they join. For some reason, my backpack stays completely empty as of testing.
Here’s what I have:
local mss = game:GetService("MemoryStoreService")
local data = mss:GetQueue(" "..tostring(plr.UserId), 30):ReadAsync(1)
if data ~= nil then
for i, v in pairs(data) do
if game.Workspace:FindFirstChild(tostring(v)) then
local item = game.Workspace[tostring(v)]:Clone()
item.Parent = plr.Backpack
In the console, it prints:
table: random numbers and letters
So everything is working, but nothing is actually in my backpack. What’s wrong?
Parent the tool in the backpack everytime their character spawns/loads.
i cant do it everytime, because then theyd have their items after they die and i dont really want that. would a wait(5) possibly work?
why not you put them on replicated storage and create a clon, and when is used, you just destroy it?
what…? (character limit eeeee)
Blud, why are u using workspace to store items
its not that big of a deal bro
It is. Either put them in serverstorage or replicated. Putting stuff thats meant to be cloned in workspace is a sin.
i dont understand why youre complaining about an item in a certain spot… but you do you… this conversation shouldnt even be happening
thats that i said, but not just that. thats just a best practice, but test your game and notice if the item apears in your backpack trough the explorer.
probably you didnt put the item with a tool part. or something that phisically isnt allowing to show the item to you
sometimes the problem is in the explorer, or someting like that, send me a screenshot to know more
its fine i solved it. i made it so it waits until the character loads, similar to what @NyrionDev said. thanks anyway
This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.