Second Sound Effect Refuses To Play

You can write your topic however you want, but you need to answer these questions:

  1. What do you want to achieve? Basically, I’m having this issue with my JoJo’s Stand Script

  2. What is the issue? With some audios, both sound effects work perfectly, while the second one simply doesn’t plays. (If the second one doesn’t plays the ActionBilboard isn’t getting destroyed)

robloxapp-20240116-0800521.wmv (2.1 MB)

  1. What solutions have you tried so far? I couldn’t find any solutions in the developer hub, cause my code is a different case

Piece Of Code:

local Three = math.random(1,3)
		
local Call = Audio.God:WaitForChild("GOD - Za Warudo Callout "..Three):Clone()
local SFX = Audio.God:WaitForChild("SFX2"):Clone()
		
SFX.Name = Player.Name.."'s "..SFX.Name
SFX.Parent = workspace
Call.Name = Player.Name.."'s Callout"
Call.Parent = workspace
Call:Play()

Call.Ended:Connect(function()
		HumanoidRootPart:WaitForChild("ActionBillboard"):Destroy()
			
		SFX:Play()

		wait(0.75)

		SFX.Ended:Connect(function()
		Call:Destroy()
		SFX:Destroy()
	end)
end)
2 Likes

Nothing seems like it would cause that problem to happen from what I can tell, so try to restructure it and see if there’s an improvement like so:

local SFX = Audio.God:WaitForChild("SFX2"):Clone()
SFX.Parent = workspace

local ActionBillboard = HumanoidRootPart:WaitForChild("ActionBillboard")

local Call = Audio.God:WaitForChild("GOD - Za Warudo Callout "..math.random(3)):Clone()
Call.Parent = workspace

Call:Play()
Call.Ended:Wait()

ActionBillboard:Destroy()

SFX:Play()
SFX.Ended:Wait()

Call:Destroy()
SFX:Destroy()

Are you sure there is an sound id actually inserted or just an empty one?

Yeah, as you can see in the video, the first two times work normally

I couldn’t fix, so I added this line

DB:AddItem(ActionBillboard,1.35)

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