YarnSpinnerTool / YarnSpinner-Unity

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

VoiceOverView fails to play the first voice line when Addressables are enabled #200

Closed fmoo closed 1 year ago

fmoo commented 2 years ago

What is the current behavior? When an yarnspinner script contains a voiced line as the very first line of dialogue, and Addressables are in use, it will fail to play as the AudioClip will not have had time to load.

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

  1. Make sure addressables and yarn localization are enabled for your project.
  2. Create an audioclip. Name and mark it addressable as appropriate.
  3. Write a .yarn script such that the first line is dialogue and includes a voice #line: ID tag that matches the addressable.
  4. Run the game and play the yarn script

What is the expected behavior? The audio line plays, regardless of whether there is a <> or not, or is the first line or not.

Please tell us about your environment:

Other information

As a workaround, I made the following changes:

McJones commented 1 year ago

Fixed in 8089131e682f15d9dd1b073cc55ca817d0125e28