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

How do i use the onClicked function?

Asked by 8 years ago

i have no idea how to use it, i know onTouch but i don't know onClicked. Do i need a click detector or something?

3 answers

Log in to vote
0
Answered by 8 years ago

You don't

The deal is, you have to find the event.

Ad
Log in to vote
0
Answered by 8 years ago

With GUI instances;

TextButton.MouseButton1Down:connect(function() --Button1 is Left Click, Button2 is left Click. Down is when the LMB is down, and Up is when LMB is Up. Same with RMB.
    --code
end)

With Parts (Click Detector);

ClickDetector.MouseClick:connect(function()
    --code
end)
Log in to vote
0
Answered by 8 years ago

This might help you: http://wiki.roblox.com/index.php?title=Making_an_onClicked_script

Answer this question