So I got help from here to make this local script. It is under PlayerGui however, when the player is in first person camera view while touching the brick, the audio literally breaks. Why?
local player = game.Players.LocalPlayer
repeat wait() until player.Character
local part = game.Workspace.Stores.GeneralStore.GeneralStoreMusic
part.Touched:Connect(function(hit)
if hit.Parent == player.Character then
player.PlayerGui.Music.GeneralStoreMusic:Play()
end
end)
part.TouchEnded:Connect(function(hit)
if hit.Parent == player.Character then
player.PlayerGui.Music.GeneralStoreMusic.Playing = false
end
end)

6 comments
Line 13 change GeneralStoreMusic:Stop() ?
You want it so when the player touches the
part, the music plays and when the player stops touching thepart, the music will stop?The script works, however when the player is in first person camera view, the audio doesn't play...
It's probably a bug, try printing when the touchended event fires: print('touch ended'), and see that if you zoom in, it prints
tell me if it does or not
It does print when the touch is ended whenever the camera moves around in first person view.