Code: Select all
public void Update()
{
if (m_isPlaying)
{
CheckQueuedCommands();
}
}
private void LateUpdate()
{
if (m_isPlaying)
{
CheckActiveCommands();
if (m_delayTimeLeft > 0)
{
switch (DialogueTime.mode)
{
case DialogueTime.TimeMode.Realtime:
m_delayTimeLeft -= Time.unscaledDeltaTime;
break;
case DialogueTime.TimeMode.Gameplay:
m_delayTimeLeft -= Time.deltaTime;
break;
}
}
if ((m_queuedCommands.Count == 0) && (m_activeCommands.Count == 0) && m_delayTimeLeft <= 0)
{
FinishSequence();
}
}
}