Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

How would I give someone a tool through a gui?

Asked by
hoth7 45
4 years ago

So I'm making a check out station where if you click a GUI, it will give you a tool. I don't know how to access a tool and put it in a person's inventory. I would love it if someone could help me with this I thought this would work but it apparently doesn't.

local tool = game.ServerStorage.Card
local klone = tool:clone()
script.Parent.MouseButton1Click:Connect (function(plr)
if klone.Parent ~= plr.Backpack then
klone.Parent = plr.Backpack
else
end
end)

Answer this question