Advertisement
Guest User

Untitled

a guest
Oct 15th, 2019
105
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.05 KB | None | 0 0
  1. _G.skip = false --execute just _G.skip=true to skip a song
  2.  
  3. local playlist = {
  4. ["High Hopes"] = "https://pastebin.com/raw/V2RPUcBP",
  5. ["High Hopes"] = "https://pastebin.com/raw/V2RPUcBP",
  6. ["High Hopes"] = "https://pastebin.com/raw/V2RPUcBP",
  7. ["High Hopes"] = "https://pastebin.com/raw/V2RPUcBP",
  8. ["High Hopes"] = "https://pastebin.com/raw/V2RPUcBP"
  9. }
  10.  
  11. function chat(msg)
  12. game:service'ReplicatedStorage'.DefaultChatSystemChatEvents.SayMessageRequest:FireServer(msg, 'All')
  13. end
  14.  
  15. function sing(url, title)
  16. local text = game:HttpGet(url, true)
  17. local lyrics = {}
  18. for s in text:gmatch("[^\r\n]+") do
  19. table.insert(lyrics, s)
  20. end
  21. local duration = #lyrics * 5
  22. chat("Duration: " .. tostring(duration) .. " seconds")
  23. for i,v in pairs(lyrics) do
  24. if _G.skip then
  25. chat("Skipping " .. title)
  26. _G.skip = false
  27. wait(1)
  28. break
  29. end
  30. wait(5)
  31. chat(v)
  32. end
  33. end
  34.  
  35. for i,v in pairs(playlist) do
  36. chat("Now playing: " .. i)
  37. sing(v, i)
  38. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement