my game has subtitles for the characters voices, lets say the player pauses the game at that time, would it be possible to pause the audio and the subtitles to like “freeze” ?
SoundInstance:Pause() and :Resume exist.
You could pause the subtitle loop by using a repeat until loop and seeing if the pause value is set to false again.
yes you can,
if your rigs have animations, just use :Pause
and :Resume
, same for sounds as @awry_y said
Animations don’t have :Pause
and :Resume
. You need to use Track:AdjustSpeed(0)
to pause an animation.
SoundInstance:Pause() does this apply to all sounds in game? or do i have to pause every sound?
also im using subtitles with text labels
No this cannot be forgiven, now empty the compartments of your pantaloons and discard all your valuables. In fact, I am the one equipped to casually summon little travis on your buffon stuff.
You need to do it for each sound as for subtitles, I would need to see your code for that.
the way i use the sounds and labels is by receiving a certain value and then display them with like a
play:() and using waits to display the textlabels so they cant match the audio
Your still using a loop right? Assuming you have a value that indicates the pause status. You could add this in your loop:
if Pause.Value then
repeat
task.wait(0.1)
until not Pause.Value
end
this is how im doing it (i havent started the pause thing yet, im still wondering how am i doing it)
Same concept then, just slap on the script after the waits and you’ll be done.
This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.