Hi!
I'm making a dialogue with a typewritter, a continue button and responses after NPC text. I would like to use the continue button but I don't want the player to be able to skip the typewriter effect.
I have been looking througt the forum but can't find any solution. I tried to activate and deactivate button's GameObject in typewritter OnBegin and OnEnd events but doesn't work.
Also if it's posible, I would like to revert this behaviour. I want the player to be able to skip the typewritter effect after the first run.
Thanks in advance
Don't show continue button until typewriter effect ends
Re: Don't show continue button until typewriter effect ends
Hi,
Use the typewriter's OnCharacter() event to deactivate the continue button. Still use OnEnd() to reactivate it.
You could implement some kind of parallel system.
Alternatively, it might be simpler to allow skipping if the conversation has been played before. See this post for an example of how to know whether a conversation has played before. You can write a script that checks of the conversation has played before. If so, add events to the typewriter's OnCharacter() and OnEnd() UnityEvents; if not, clear those UnityEvents.
Use the typewriter's OnCharacter() event to deactivate the continue button. Still use OnEnd() to reactivate it.
That's a little complicated. The Dialogue System has a feature called SimStatus that keeps track of whether each dialogue entry node has been displayed or not. But it sets SimStatus to "WasDisplayed" just before showing the text. So you can't hook into the text-showing method to decide whether or not to show the continue button.
You could implement some kind of parallel system.
Alternatively, it might be simpler to allow skipping if the conversation has been played before. See this post for an example of how to know whether a conversation has played before. You can write a script that checks of the conversation has played before. If so, add events to the typewriter's OnCharacter() and OnEnd() UnityEvents; if not, clear those UnityEvents.