But if the same character play voice in two subtitle, A next is B. pre subtitle play A, the next subtitle play B. Beacuse A will wait 0.1s to destoy so that will stop playing voice in B
that is the code
Code: Select all
public void StopActive()
{
foreach (var command in m_activeCommands)
{
if (command != null)
{
if (!string.IsNullOrEmpty(command.endMessage)) Sequencer.Message(command.endMessage);
Destroy(command, 0.1f);
}
}
m_activeCommands.Clear();
}