YarnSpinnerTool / YarnSpinner-Unity

The official Unity integration for Yarn Spinner, the friendly dialogue tool.
MIT License
491 stars 85 forks source link

Effects.Typewriter fails when TimeScale is 0 #239

Closed danielk-sn closed 1 year ago

danielk-sn commented 1 year ago

What is the current behavior?

Using the "Phone Chat" sample, no chat test displays when starting the conversation if the timescale is set to zero

Please provide the steps to reproduce, and if possible a minimal demo of the problem:

Import "Phone Chat" sample and open scene. Add the following to the PhoneChatDialogueHelper script:

void OnEnable()
{
    Time.timeScale = 0;
}

What is the expected behavior?

Chat text display even if timescale is zero

Please tell us about your environment:

Other information

Some way to change the effects to run if timescale is zero. Since it uses Time.deltaTime, this prevents it from progressing. Either a way to flip over to unscaledDeltaTime or an easier way to extend the effect so that I can override it. Updating only the Effect doesn't seem to be enough

McJones commented 1 year ago

This is a duplicate (essentially) of #202