Whenever I run my music script, the PreloadAsync()
yields infinitly. No errors showed up, but a Print()
function I set up never fires and the music doesn't play. (The original script had about 8 songs, but I had to shorten it to make it fit.)
content = game:GetService("ContentProvider") music = {"rbxassetid://1581067887","rbxassetid://553600220"} content:PreloadAsync(music) while true do local pick = math.random(1,table.getn(music)) local song = music[pick] script.Music.SoundId = song script.Music:Play() print("Music Playing") wait(script.Music.TimeLength) end
Turns out that the input in to the PreloadAsync is a table of the actual objects, not the asset ids.