Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- --TYPE SCRIPT
- MusicPlayerInstantiate = Instance.new("Sound")
- MusicPlayerInstantiate.Parent = game.Workspace
- MusicPlayerInstantiate.Name = "Music"
- urlAPI = "http://www.roblox.com/asset/?id="
- IdSounds = {"3291366970", "2578125671"}
- local MusicPlayer = Workspace:WaitForChild("Music")
- while true do
- MusicPlayer.SoundId = urlAPI .. IdSounds[math.random(1, #IdSounds)]
- MusicPlayer:Play()
- print("Duracion " .. MusicPlayer.TimeLength)
- wait(MusicPlayer.TimeLength)
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement