So I was making a radio and the music wouldn’t loop even though i put Sound.Loop = True
Heres the code:
if Audio.IsPlaying == true then
Sound.Looped = true
is Playing property true or false? (while editing in studio)
Yeah, I think so but it still play the audio, when the music ends it just stops playing. I want it to loop the song infinitely
can you add
print("Playing!") above the
Sound.Looped = true and tell me if it prints?
Alright lemme do that real quick
Ok so it printed, so what now?
why are you stopping sound if it’s playing?
Wait what do you mean by that??
you’re stopping the sound here. Isn’t it pointless? you don’t need to stop the sound. So you don’t need Sound:Play() too because it’s already playing the sound when you join.
By what you provided in the script you’re only checking once if the audio is playing. Also you’re stopping the audio as soon as it plays.
Something like this should work.
local Audio = script.Parent:FindFirstChild("Music")
Audio.Looped = true
Oh I see now, I don’t know why I wrote that. Should i remove it?
yes and why don’t you just set Looped property to true manually?
Ok I tried this and it worked, it started to loop
Thank you everyone for the help!