So... My script allows an audio to be played whenever a mouse hover on top of it. I want a different sound to be played when you click on it. It plays the sound when you hover and click on it.
I've tried Button1Down but, it doesn't seem to really work (probably because I'm using it wrong or something)
Can anyone fix my script? Thanks! P.S. Please make it Filtering Enabled compatible.
Local Script
function MouseEnter()
script.Parent.Click:Play()
end
script.Parent.MouseButton1Click:connect(function()
script.Parent.Parent.Deploy.BackgroundTransparency = .7
wait(.1)
script.Parent.Parent.Deploy.BackgroundTransparency = .5
script.Menu.Loading.Visible = true
end)
script.Parent.MouseEnter:connect(MouseEnter)

4 comments
oh my lack of indents i might explode
HAHA, just put the "script.Parent.MouseEnter:connect(MouseEnter)" above the "End)", gg
What? No
It works, I just have difficulties shifting things around. I'm fairly new to programming, and Lua is my first coding language I'm learning.