this is a bit of code i tried and it worked (i got the item) but it didnt takeaway money can anyone help?
function Give(x) local y = x.Backpack local z = game.Lighting["Octopus"] z:Clone().Parent = y end script.Parent.ClickDetector.MouseClick:connect(Give)
you need to make a local script where you going to click the button and then make a event to prevent hackers and check if the player have enough money if he do you going to take away money copy the item and put it in the player inventory this is the best answer you can get because its more then just a script