I have this Surface GUI script here, that I can't get working.
local button = script.Parent
plr = game.Players.LocalPlayer
tool = game.Lighting("AK-47")
function onClick()
tool:Clone().Parent = plr.Backpack
end
button.MouseButton1Click:connect(onClick)
Any kind of help will be greatly appreciated.

3 comments
What is script.Parent? Add the explorer window.
Make sure your GUI is inside the player's gui, else it won't recognize their input. Also, don't forget to set the gui's adornee to your desired part.
Script.Parent is a TextButton