The title explains it.. i would like to have some help with this please! Some examples of games with this is.. https://web.roblox.com/games/4983678402/ , and https://web.roblox.com/games/5108696463/
--Not including this with every single gui you make-- script.Parent.Sound:Play()
also: (Without scripting every gui) (Including roblox core ui buttons)
Hopefully somebody could help me with this .. thank you!
put the code below in a local script inside of a screen gui.
for _, v in pairs(script.Parent:GetDescendants()) do if v:IsA("TextButton") then v.MouseButton1Click:Connect(function() sound:Play() end) end end
hope this helps, and remember do not put this inside of a textbutton or any other object, just a local script inside of the screen gui.
Simple, Just follow this script! Please accept and upvote if helped!
script.Parent.MouseButton1Click:Connect(function() sound:Play end)