How do i script a button to dispense an item? i just started scripting and i don't know how to do this! Please Help!
COMMUNITY QUESTION
How to Script? (Very Easy to Answer)
2 answers
Now THIS IS NOT A REQUEST SITE So I will not give you the full code. I will however give you some help with the function you will need, Put in the block inside a Script.
function onClicked()
--CODE HERE
end
script.Parent.ClickDetector.MouseClick:connect(onClicked)
You can learn how to do the rest here: wiki.roblox.com
Well, since this isn't a request site, I will only point you to where you need to go. Go here: wiki.roblox.com. Then, search: Instance.new.
This discussion is preserved as it was. New answers, comments, and votes are closed.

1 comment
This is not a request site. You must put a attempt with your question. Also here's a list of sources to help you begin to script. https://scriptinghelpers.org/questions/9539/how-should-i-start-to-code#12184