irve wrote:Could we get OnSequenceStart() and OnSequenceEnd() on the DialogueManager gameObject? Currently we only get it on the speaker and listener.
Yes. I'll add that in a patch and publish it this week.
irve wrote:Or is there any other way to get a callback on the sequence being ready?
If you're using Unity UI Typewriter Effect, it has OnBegin, OnCharacter, and OnEnd events. I don't know if that would be helpful. Without having to write any code, you could add an event to OnBegin that sets the continue button's text to "Skip", and add an event to OnEnd that sets the continue button's text to "Continue".
If you don't want to time this according to the typewriter effect, another way is to use the @Message and ->Message syntax inside the sequence. For example:
Code: Select all
SendMessage(ChangeContinueText,Skip,MyGameObject);
AudioWait(Voiceover/blahblahblah)->@Message(DoneTalking);
SendMessage(ChangeContinueText,Continue,MyGameObject)@Message(DoneTalking)
This assumes you have a GameObject named MyGameObject with a script that has a method ChangeContinueText(string newValue):
Code: Select all
public UnityEngine.UI.Button continueButton;
public void ChangeContinueText(string newValue) {
continueButton.GetComponentInChildren<UnityEngine.UI.Text>().text = newValue;
}