Advertisement
ShutUpJamesTheLoser

he

Mar 6th, 2025
105
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.95 KB | None | 0 0
  1. local function createSound(id, playbackSpeed)
  2. local sound = Instance.new("Sound")
  3. sound.SoundId = "rbxassetid://" .. id
  4. sound.Volume = 10
  5. sound.PlaybackSpeed = playbackSpeed
  6. sound.Parent = workspace
  7. return sound
  8. end
  9.  
  10. local sounds = {
  11. createSound("126661876829169", 0.4),
  12. createSound("78154888193339", 0.4),
  13. createSound("110726080164032", 0.4)
  14. }
  15.  
  16. local skybox = Instance.new("Sky")
  17. skybox.SkyboxBk = "rbxassetid://172423468"
  18. skybox.SkyboxDn = "rbxassetid://172423468"
  19. skybox.SkyboxFt = "rbxassetid://172423468"
  20. skybox.SkyboxLf = "rbxassetid://172423468"
  21. skybox.SkyboxRt = "rbxassetid://172423468"
  22. skybox.SkyboxUp = "rbxassetid://172423468"
  23. skybox.Parent = game.Lighting
  24.  
  25. local function playSequence(index)
  26. sounds[index]:Play()
  27. sounds[index].Ended:Connect(function()
  28. if sounds[index + 1] then
  29. playSequence(index + 1)
  30. else
  31. skybox:Destroy() -- Remove the Skybox when the last sound ends
  32. end
  33. end)
  34. end
  35.  
  36. playSequence(1)
  37.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement