Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

Gui button will not give me tool in surface gui but on screen gui?

This button gives a tool on click, but only works when in side a screen gui. It wont even select when placed in a surface gui, what is happening? I do not think you need the script but the problem might be in the script.

you=script.Parent.Parent.Parent.Parent.Parent
script.Parent.MouseButton1Click:connect(function()
if script.Parent.Selected==false then
if game.Lighting:findFirstChild("Tool") then
Tool=game.Lighting.Tool:clone()
Tool.Parent=you.Backpack
script.Parent.Selected=false
wait(2)
script.Parent.Selected=true
end
end
end)

1 answer

This discussion is preserved as it was. New answers, comments, and votes are closed.