AudioWait - Make the dialogue advance manually after the audio sequence is finished?
AudioWait - Make the dialogue advance manually after the audio sequence is finished?
Currently AudioWait automatically advances through the conversation once the voice is finished playing. Is there any way to make it manual, since the dialogue script doesn't fire up when the conversation advances automatically?
Re: AudioWait - Make the dialogue advance manually after the audio sequence is finished?
Hi,
Which dialogue script are you referring to? If you're referring to the Script field on the dialogue entry node, it should run before AudioWait(). Take this node for example:
This will happen in order:
1. The Script field executes.
2. The Dialogue System raises the OnConversationLine event to any relevant scripts or Dialogue System Events components.
3. The subtitle panel shows "Hello world."
4. The Sequence plays: AudioWait(hello)
5. The conversation waits until the Sequence is done -- which is when the AudioWait() command finishes in this case. Then it advances to the next stage in the conversation (e.g., next subtitle or response menu).
Which dialogue script are you referring to? If you're referring to the Script field on the dialogue entry node, it should run before AudioWait(). Take this node for example:
This will happen in order:
1. The Script field executes.
Code: Select all
Variable["Said_Hello"] = true
3. The subtitle panel shows "Hello world."
4. The Sequence plays: AudioWait(hello)
5. The conversation waits until the Sequence is done -- which is when the AudioWait() command finishes in this case. Then it advances to the next stage in the conversation (e.g., next subtitle or response menu).
Re: AudioWait - Make the dialogue advance manually after the audio sequence is finished?
Yeah, it's Dialogue node's script field. But apparently it doesn't run before AudioWait() starts. For example, when I put AudioWait sequencer and a script to animate a sprite in the same dialogue node, the animate sprite script doesn't play - just the dialogue audio.
Re: AudioWait - Make the dialogue advance manually after the audio sequence is finished?
Is the animation in the Script field or Sequence field? Can you please post a screenshot of the inspector view of the node?RX-310 wrote: ↑Tue Feb 04, 2020 12:36 amYeah, it's Dialogue node's script field. But apparently it doesn't run before AudioWait() starts. For example, when I put AudioWait sequencer and a script to animate a sprite in the same dialogue node, the animate sprite script doesn't play - just the dialogue audio.
If you're calling a custom Lua function in the Script field, try adding a Debug.Log line to make sure the function is actually getting called when you expect it to.