No sound when i playtest

I am making a tower defense game and there is a bug when I play test the game, there is a 50% chance the audios will actually play. By this I mean that the playtest is completely muted (the death sound doesn’t even play when I adjust my volume).
Sometimes after I re-playtest the game the audio enables. Also nothing comes up in the output.

Is there any way I can fix it so that the audio plays each time?

  1. What do you want to achieve? A fixed Roblox Studio audio

  2. What is the issue? About half the time I playtest, the Roblox Studio audio is completely muted

  3. What solutions have you tried so far? I tried restarting my pc

4 Likes

Maybe if you can paste the section where you are requesting the audio to play someone can help.

1 Like

I’ve been having the same problem, I think its a roblox studio problem

1 Like
local rs = game.ReplicatedStorage
local player = game.Players.LocalPlayer

local runservice = game["Run Service"]

for i,v in pairs(script.Parent:GetChildren()) do
	if v:FindFirstChild("TextButton") then
		v.TextButton.MouseEnter:Connect(function()
			local hotkey = v:FindFirstChild("HotkeyNumber")

			if hotkey then
				game.SoundService.pop:Play()
				
				tweenservice:Create(v.Frame,TweenInfo.new(.1,Enum.EasingStyle.Sine,Enum.EasingDirection.In),{Size = UDim2.new(1.1,0,1.1,0),Position = UDim2.new(.5,0,.4,0)}):Play()
			end
		end)
		v.TextButton.MouseLeave:Connect(function()
			local hotkey = v:FindFirstChild("HotkeyNumber")

			if hotkey then
				
				tweenservice:Create(v.Frame,TweenInfo.new(.1,Enum.EasingStyle.Sine,Enum.EasingDirection.In),{Size = UDim2.new(1,0,1,0),Position = UDim2.new(.5,0,.5,0)}):Play()
			end
		end)
	end
end


1 Like

Maybe start with some print commands:

Try adding one just before the Play() and see if it prints every time.

local rs = game.ReplicatedStorage
local player = game.Players.LocalPlayer

local runservice = game["Run Service"]

for i,v in pairs(script.Parent:GetChildren()) do
	if v:FindFirstChild("TextButton") then
		v.TextButton.MouseEnter:Connect(function()
			local hotkey = v:FindFirstChild("HotkeyNumber")

			if hotkey then
				print("Play Sound")
				game.SoundService.pop:Play()
				
				tweenservice:Create(v.Frame,TweenInfo.new(.1,Enum.EasingStyle.Sine,Enum.EasingDirection.In),{Size = UDim2.new(1.1,0,1.1,0),Position = UDim2.new(.5,0,.4,0)}):Play()
			end
		end)
		v.TextButton.MouseLeave:Connect(function()
			local hotkey = v:FindFirstChild("HotkeyNumber")

			if hotkey then
				
				tweenservice:Create(v.Frame,TweenInfo.new(.1,Enum.EasingStyle.Sine,Enum.EasingDirection.In),{Size = UDim2.new(1,0,1,0),Position = UDim2.new(.5,0,.5,0)}):Play()
			end
		end)
	end
end
1 Like

I eat noodles loudly too, anyways.

check if the functions actually run, when you play the game

2 Likes

Roblox recently has the game muted by default when you playtest, the only way to remedy the issue is to mute and unmute the game and the sounds should return. It’s quite irritating.

1 Like

i know its playing because the rest of the script works and everything, its just that studio is completely muted and i cant even hear the oof sound when i adjust my volume

1 Like

could you explain how i could do that?

1 Like

Alt Tab, when your focus is off roblox studio when you playtest and you reenter the sounds usually off. Easiest solution is to just alt tab and click back in. At least thats what i do.

1 Like

Check your output in the roblox menu (Escape), when your playtesting.

Roblox automatically puts your output to your system’s DEFAULT, go to your sound settings and make the output you use, your default, there are tutorials on yt on how to do that, Im not gonna get into detail.
Free solve??

Now you can eat your noodles loudly, and hear the playback.

---Or you just click on and off until its not muted.
1 Like

I have this problem, you have to click on and off Roblox Studio multiple times until the sound is no longer muted.

thanks for the answers! ill try to test them out to see if they work!

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.