How do i make this Music Player Play for everyone

Hi i made a speaker that plays music but im the only one who can hear it how do i fix that
local workspaces = game:GetService(“Workspace”)
workspaces.RadioMesh.ClickDetector.MouseClick:Connect(function(player)
if player.Name == “Tunnells” then
player.PlayerGui.Music.Enabled = true

	wait(5)

	player.PlayerGui.Music.Enabled = false
else
	print("Your are not a admin")
end

end)

local sound = workspaces.RadioMesh.Sound
local button = script.Parent.TextButton
local box = script.Parent.TextBox

script.Parent.Stop.MouseButton1Click:Connect(function()
sound:Stop()
end)

button.MouseButton1Click:Connect(function()
sound.SoundId = “rbxassetid://”… box.Text
sound:Play()

script.Parent.Increase.MouseButton1Click:Connect(function()
	sound.Volume = sound.Volume + 1
end)

script.Parent.Decrease.MouseButton1Click:Connect(function()
	sound.Volume = sound.Volume + -1
end)

end)
This is the setup
image

Use a server script instead of a local script

It doesnt work it :frowning: i try but it doesnt play and no error

Could you check what the Properties on the Sound are? You may need to change it to LinearSquared and change the Max/Min Off distances?

Are there any errors showing up in the Output window? If so please post a screenshot of them.

The reason this happens is because your music needs to be in workspace (or a folder in workspace) because the workspace is made on the server. If on the workspace everyone can hear is perfectly with no volume changes.

1 Like

It is in the Workspace i think the problem is it doesnt change the SoundIDanymore

Try using remote events. Fire from the local script and pick it up on a server script.

Im not the best with Remote Events :frowning:

If no one is able to hear your music player, it’s not the script issue.
It’s the SoundService’s issue.

Solution: Go to SoundService and turn off “RespectFilteringEnabled”.
Try and check if it solves the issue.

just play the sound on the server lol

Useful Links:

1 Like

One problem im not sure how to fix is 08:22:29.739 ▶ Failed to load sound rbxassetid://: Unable to download sound data (x2) - Studio

It means the asset (which is sound) is failed to load. In most cases, the SoundID is not inserted correctly or Roblox is down.
I’m not sure if there are any other reasons for this error.

1 Like