I want it to play a different one than the one it played previous. How do I do this?
--AllianceScripter's Radio--
local music = script.Parent
local gui = script.Parent.Parent
local talk = script.Parent.Parent.Talk
local justplayed = {}
local musicids = {181547615,142376088}
while true do wait()
local ran = (musicids[math.random(1,2)])
music.SoundId = "http://www.roblox.com/asset/?id="..ran
table.remove(musicids,ran)
table.insert(justplayed,ran)
music:Play()
while true do wait()
if talk.IsPlaying == false then
wait(120)
for i = 0.5,0,-0.1 do
music.Volume = i
wait(0.01)
end
music:Stop()
wait(2)
music.Volume = 0.5
music:Play()
table.remove(justplayed,ran)
table.insert(musicids,ran)
end
end
end
