Author Topic: Pausing and unpausing linked channels when the linked channel has ended  (Read 110 times)

srylain

  • Posts: 18
Say I have multiple channels that are playing simultaneously, and the channel that is the one the other channels are linked to has ended while the others are still playing. When I try to Pause that linked channel, nothing happens because I assume that it's already ended so nothing is done so the other channels keep playing. Same thing happens when I try to play the stopped channel, none of the other channels play.

So to get around that, I end up running a loop that pauses the other channels if the linked channel is inactive and when trying to play it I set the byte position of the channel back by one byte and then play it. So far this seems to work, but is there a better way to do something like this?

EDIT: Earlier I was linking the channels to the first channel that was given audio, instead I'm now linking the channels to the channel with the longest audio and it seems to have fixed the problems I was having.
« Last Edit: 3 Nov '17 - 01:40 by srylain »