Need help with Animating response window

Announcements, support questions, and discussion for the Dialogue System.
User avatar
Shinos
Posts: 59
Joined: Tue Jan 17, 2023 10:51 am

Need help with Animating response window

Post by Shinos »

Hi, so i was following this tutorial

and everything was working good but after i got to the animation section something weird began to happen, my response window only at the 1st question opens too soon and the buttons takes time to appear and also when the dialogue is over it takes a lot of time for the dialogue background to disappear, if i deactivate the animator all of this does not happen

here is a demonsatration


for the first issue: looking at the animator windows it is like the Show trigger is instantaneously activated but i don't know why
User avatar
Tony Li
Posts: 21961
Joined: Thu Jul 18, 2013 1:27 pm

Re: Need help with Animating response window

Post by Tony Li »

Hi,

Take a look at one of the animator controllers that ship with the Dialogue System, such as Canvas Group Animator Controller. It has a Start/Hidden state that keeps the panel hidden, and Show & Hide triggers that show and hide the panel. Try a similar setup in your animator controller.

The dialogue panel is taking 10 seconds to hide probably because it's timing out after failing to enter the hide state. Check the names of the trigger parameters assigned to the dialogue panel's UIPanel component > Show Animation Trigger and Hide Animation Trigger. Make sure they corresponding to trigger parameters in the dialogue panel's animator controller.

Another possibility is that it's waiting for a subtitle panel or menu panel to report that it's hidden, and timing out while waiting.
User avatar
Shinos
Posts: 59
Joined: Tue Jan 17, 2023 10:51 am

Re: Need help with Animating response window

Post by Shinos »

Hi Tony
I checked and everything is set up right like in the video, i could try to change the animator architecture to the one you mentioned with "start" but still there is no reason why it's behaving this way and not like in the tutorial.
https://ibb.co/H2dbbp3

i can't understand why as soon as the dialogue start the "Show" trigger is triggered, you can see that also in the video i sent
Also i just witnessed that the reply window comes out without response even if the player does not have lines of speech when i activate the animator
User avatar
Shinos
Posts: 59
Joined: Tue Jan 17, 2023 10:51 am

Re: Need help with Animating response window

Post by Shinos »

i did another video to show the issue:
User avatar
Shinos
Posts: 59
Joined: Tue Jan 17, 2023 10:51 am

Re: Need help with Animating response window

Post by Shinos »

Ok i'm an idiot i didn't put the Menu Panel reference in the Standard UI menu panel, i'm sorry.

It all works now the only thing i am trying to figure out now is why there is a little delay from the end of the sentence and the start of the animation of the response panel, like a 0.2 seconds, checking if it is possible to make it instantaneous.

PS: this also got me thinking in reverse, is it possible to delay the start of a conversation after the player press the interaction button on an npc? like if i would like for an npc to do a little 1 sec animation and then start the conversation
User avatar
Tony Li
Posts: 21961
Joined: Thu Jul 18, 2013 1:27 pm

Re: Need help with Animating response window

Post by Tony Li »

Hi,

If you want to show the response panel as soon as the typewriter finishes, set the Dialogue Manager's Display Settings > Camera & Cutscene Settings > Default Sequence to:

Code: Select all

WaitForMessage(Typed)
This will make the subtitle wait until the typewriter sends the sequencer message "Typed" when it's done.
User avatar
Shinos
Posts: 59
Joined: Tue Jan 17, 2023 10:51 am

Re: Need help with Animating response window

Post by Shinos »

Thank youit seems to work!
and what about the other topic?
PS:this also got me thinking in reverse, is it possible to delay the start of a conversation after the player press the interaction button on an npc? like if i would like for an npc to do a little 1 sec animation and then start the conversation
also i was wondering what the already written code "Delay({{end}})" does? Because i just noticed that if i keep both Delay({{end}}) and WaitForMessage(Typed) it does not work as intended and instead it shows everything both response and dialogue instantaneously

Also i don't know if i'm misunderstanding how this works but i just noticed that i can apply it also individually to sentences by going in the conversation editor in the "Sentence" tab so it is really versatile
User avatar
Tony Li
Posts: 21961
Joined: Thu Jul 18, 2013 1:27 pm

Re: Need help with Animating response window

Post by Tony Li »

Hi,

Yes, that's correct. If you want to play a different sequence for a specific dialogue entry, you can set its Sequence field. If the Sequence field is blank, it will play the Dialogue Manager's Default Sequence.

You can also play the Default Sequence in a dialogue entry's Sequence field by adding the {{default}} keyword, like:

Code: Select all

{{default}};
AudioWait(hello_world)
(Note that commands, including {{default}}, need to be separated by semicolons.)

The keyword {{end}} represents a duration based on the text length and the values of the Dialogue Manager's Subtitle Settings > Subtitle Chars Per Second and Min Subtitle Seconds. For example, if the text is 120 characters and Subtitle Chars Per Second is 30, then {{end}} will be 120 / 30 = 4 seconds. So the command Delay({{end}}) will be equivalent to Delay(4), which delays for 4 seconds before ending the dialogue entry and advancing the conversation.

More info: Cutscene Sequences. The top of this page has a link to a video tutorial series if you prefer videos over text.
User avatar
Shinos
Posts: 59
Joined: Tue Jan 17, 2023 10:51 am

Re: Need help with Animating response window

Post by Shinos »

Hi,
Thanks Tony, i just got here to say that i have just began to see the Cutscene videos and i got my answer in the very first minutes of the 1st video but you got here before me :oops:
Also i think i just found also the answer to my second doubt in the first answer you gave in this post
correct me if i am wrong
https://www.pixelcrushers.com/phpbb/vie ... php?t=2353
what i am trying to achieve is to delay the start of a conversation after you start the interaction.
also if i understood it well i found in your last answer of this other post how to delay and hide the subtitle panel in between of a conversation and then continue the conversation again
https://www.pixelcrushers.com/phpbb/vie ... php?t=4043
User avatar
Tony Li
Posts: 21961
Joined: Thu Jul 18, 2013 1:27 pm

Re: Need help with Animating response window

Post by Tony Li »

Hi,

Yes, you have that all correct.
Post Reply