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

Why does my click detector script does not work on an image label?

script.Parent.MouseButton1Down:Connect(function()

	print(script.Parent.Name)

end)

pic of my explorer: https://imgur.com/a/ahrm9tS the script i am curently working on is the "Deploi" one. Also i have tested this on an empty baseplate and worked just fine

Any help is apriciated!

1 comment

0

I don't get what you are trying to do here?

2 answers

Hello,

Try to make that script a Local Script. When you are trying to manipulate a StarterGui, you need to change it Locally, thus you need to use a local script.

The MouseButton1Down event cannot be used with an ImageLabel as it does not have that event. It is not meant to be a button or clicked on.

To fix that, use an ImageButton which is clickable. TextLabels also cannot use MouseButon1Down but TextButtons can for future reference.

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