question about subtitle

Announcements, support questions, and discussion for the Dialogue System.
Post Reply
joeylu
Posts: 111
Joined: Sun May 17, 2020 1:07 pm

question about subtitle

Post by joeylu »

Hi Tony,
Is it possible to showing multiple lines in one subtitle (perhaps from one dialogue entry) in a sequence?
For instance, there's a Dialogoue Entry:
"The little boy picks an axe. He laughs, then he left"

I'd like to break it to 3 lines, but showing within one subtitle box, something like:
"The little boy picks an axe"
"He laughs"
"He left"

Even better, if I can set a delay between each lines to display
My first thought is that seeking possibility with TextMeshPro GUI tags, but no luck (or I missed it)
My second solution is to implement something like custom dialogue sequence and analyze custom tags then reformat the text

What's your advice? tks
User avatar
Tony Li
Posts: 22112
Joined: Thu Jul 18, 2013 1:27 pm

Re: question about subtitle

Post by Tony Li »

Hi,

If you want to accumulate all lines, you can tick the subtitle panel's Accumulate Text checkbox. This is how games like Disco Elysium work.

If you only want to do it in very specific places, I recommend using RPG Maker-style control codes. Example:
  • Entry 1: "The little boy picks an axe."
  • Entry 2: "\>The little boy picks an axe.\< \n He laughs."
  • Entry 2: "\>The little boy picks an axe \n He laughs.\< \n He left."
You can use actual line breaks where I put "\n". Or you can use "\n" to indicate a line break. Using "\n" was just easier to show in the forum's list format above.
joeylu
Posts: 111
Joined: Sun May 17, 2020 1:07 pm

Re: question about subtitle

Post by joeylu »

tks Tony, but what if I need a delay in each line in one subtitle box? for instance,

"The little boy picks an axe" (wait 1 second, then show next line)
"He laughs" (wait 1 second, then show next line)
"He left"
User avatar
Tony Li
Posts: 22112
Joined: Thu Jul 18, 2013 1:27 pm

Re: question about subtitle

Post by Tony Li »

Hi,

Set the Sequence to: Delay(1)

Or, if you normally require the player to click a continue button to advance: Continue()@1

Note: If you use a typewriter effect and want to wait 1 second longer after the typing has finished, use: Delay(1)@Message(Typed)
joeylu
Posts: 111
Joined: Sun May 17, 2020 1:07 pm

Re: question about subtitle

Post by joeylu »

Sorry I'm confused, Isn't Delay(x) for Sequence command? Do you mean that I can put the sequence command into between the dialogue text?
Or if I didn't explain it clearly, my previous example are in one single entry, with three line breaks, so they can be displayed in one single subtitle panel. And is it possible to add a delay at the end of each line? (not each entry)
tks
User avatar
Tony Li
Posts: 22112
Joined: Thu Jul 18, 2013 1:27 pm

Re: question about subtitle

Post by Tony Li »

I was suggesting to use 3 separate dialogue entries with their own Sequences.
joeylu
Posts: 111
Joined: Sun May 17, 2020 1:07 pm

Re: question about subtitle

Post by joeylu »

What I'm trying to achieve is that when Texts are played in the same subtitle, Each lines can be showing by order with a sequences of delays. Something like showing

3 (wait for 1 second)
2 (wait for 1 second)
1

to attract player's awareness, it would be much better to show above 3 lines in one subtitle box instead divided by 3 entries, I guess I need to write a custom sequence or LUA script to handle the effects.
But tks for the replies anyway, let me know if you have any different thoughts or approaches.
User avatar
Tony Li
Posts: 22112
Joined: Thu Jul 18, 2013 1:27 pm

Re: question about subtitle

Post by Tony Li »

The 3 separate entries would appear to the player as a single entry. But you can do it in a single entry, too, if you're using a typewriter effect:
  • Dialogue Text: "The little boy picks an axe.\.\nHe laughs.\.\n He left."
  • Sequence: Delay(1)@Message(Typed)
joeylu
Posts: 111
Joined: Sun May 17, 2020 1:07 pm

Re: question about subtitle

Post by joeylu »

Ah, yes, you are totally right, I missed the \. part from your first reply
Thank you Tony
User avatar
Tony Li
Posts: 22112
Joined: Thu Jul 18, 2013 1:27 pm

Re: question about subtitle

Post by Tony Li »

Glad to help!
Post Reply