I want a player to touch a part then it locally plays the music
script.Parent.Touched:Connect(function(plr)
local sound = game.Lighting.PlayerMusic
sound.SoundId = "rbxassetid://301964312"
sound:Play()
end)
I want a player to touch a part then it locally plays the music
script.Parent.Touched:Connect(function(plr)
local sound = game.Lighting.PlayerMusic
sound.SoundId = "rbxassetid://301964312"
sound:Play()
end)
In order for a sound to be heard, the Sound object needs to be in a part in the Workspace, not in Lighting.
This discussion is preserved as it was. New answers, comments, and votes are closed.
1 comment
https://developer.roblox.com/en-us/articles/sounds-and-music