So, I’m trying to have a permanent audio player that switches to another soundid after the currently played one finished, but the thing is, it doesn’t switch, it just repeats the last played soundid.
The Script is placed inside Music, which is in Workspace
The Script looks like this:
local Themes = {733298638, 2533140135, 475011760, 721477744, 705342826, 706837670, 516104812, 705334495, 705326459, 2441582257, 1571892231}
local MaxVolume = .25
while true do
while script.Parent.Volume > 0 do
script.Parent.Volume = script.Parent.Volume - wait()/40
end
script.Parent.SoundId = "rbxassetid://" .. Themes[math.random(#Themes)]
script.Parent.TimePosition = 0
while script.Parent.Volume < MaxVolume do
script.Parent.Volume = math.min(MaxVolume,script.Parent.Volume + wait()/40)
end
wait(math.random(360,600))
end
The most I tried was changing this part:
Themes[math.random(#Themes)]
I also think that said part is the main issue, but I can’t think of any way to actually randomize the table of Id’s
I would be really thankful if you could help me figure this out!