So apparently I'm trying to make a script where if the part1 finished, it will play part2
local part1 = game.Workspace.Sound1.IsPlaying.False local part2 = game.Workspace.Sound2.IsPlaying.False game.Players.PlayerAdded:connect(function(player) game.Workspace.Sound1:Play() end) if part1 then game.Workspace.Sound2:play() else if part2 then game.Workspace.Sound1:play() end end for _, player in pairs(game.Players:GetPlayers()) do PlayerAdded(connect) -- Use your player added handling function here. end
This is the full script. The problem is, i can't get the sound to play whenever a player joins. As you can see, the part 1 and part 2 is called "Sound 1" and "Sound 2". Basically they are trying to play Smile HD [1/2] and [2/2] (placeholder music) then if part 2 finishes, part 1 will loop back again. I added the last paragraph of the script so it'll supposed to play in Solo Mode since the Wiki said it won't entirely work due to a bug or something. Anyone help? Maybe a little cleanup since i only know the basics of programming and not entirely the advanced of it.
I'm not an expert but I think the problem is in the first 2 columns
local part1 = game.Workspace.Sound1:Stop() local part2 = game.Workspace.Sound2:Stop()