Hi I am wondering how can I code my code to know when a player isn't clicking on my gui button
Example of player clicking button now how can I check if they aren't??
script.parent.Mousebutton1clickdown:connect(function()
end)
Hope you understand what I mean very hard to explain
Thanks
Sound script
local Button = script.Parent
local Clicked = false
Button.MouseButton1Down:Connect(function()
Clicked = true
while Clicked do
game.ReplicatedStorage.Sound:FireServer()
wait(.2)
end
game.ReplicatedStorage.Soundstop:FireServer()
end)
Button.MouseButton1Up:Connect(function()
Clicked = false
end)

4 comments
not quite what I wanting I got a sound system and the player holds the button to play sound. Soon as they let go of the button I want to sound to stop
I just tested it with your code and it didn't work
It would work, you just need to modify it to work with your code.
Thank you it works!! Though with the system I got to play the sound there is a cut if you know how to fix that I updated my post if not still this works perfectly so thanks