Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
-1

Help with sounds?

Asked by 9 years ago

I'm making a simple music changer and using Stopped:wait() so it checks if the music has ended and putting other music on, I'm not sure if this is the way cause someone told me to use Stopped:wait(). I'm basically saying how can i check if the sound has ended?


Sound.Stopped:wait() Sound:Destroy()

1 answer

Log in to vote
0
Answered by
Azmidium 388 Moderation Voter
9 years ago

Here is some example code that can describe what you can do.

repeat wait() until not Sound.IsPlaying
Sound:Destroy()

What the code is basically doing is gonna repeat wait() until the song ends or IsPlaying = false.

I hope this helped!

Sincerely, jmanrock123

0
Thank you, I hope this works! UltraUnitMode 419 — 9y
0
Please accept if it does, :) Azmidium 388 — 9y
Ad

Answer this question