Problems using voice in NVL mode/ center yalign
Posted: Wed Feb 09, 2022 5:51 am
Hi all,
I have a problem displaying my nvl text which uses voice. I want a block of text to be centered vertically, but my voice files are split in two. At the moment, the code has yalign 0.5 and works as it should... However, the additional lines appear underneath and are squashed at the bottom of the screen. I would like the whole block of text to be vertically aligned, not just the first line.
I know the best way to do this is to have a bigger paragraph and break it up with {w} or {nw}, but I have two voice files and I want to keep them separate so the player isn't overwhelmed by narration.
I either need a solution to start the second voice file mid paragraph (and use {w}), or I need to be able to center yalign a block of text.
I have several voiced narration blocks like this, so the height will be different each time, meaning I can't tweak the padding to make it work (unless I make several nvl styles...)
Here is my text block:
And my nvl code in GUI:
I feel like this is probably possible, but after searching the forums for a while, I can't find a solution for this particular problem.
Thank you in advance
I have a problem displaying my nvl text which uses voice. I want a block of text to be centered vertically, but my voice files are split in two. At the moment, the code has yalign 0.5 and works as it should... However, the additional lines appear underneath and are squashed at the bottom of the screen. I would like the whole block of text to be vertically aligned, not just the first line.
I know the best way to do this is to have a bigger paragraph and break it up with {w} or {nw}, but I have two voice files and I want to keep them separate so the player isn't overwhelmed by narration.
I either need a solution to start the second voice file mid paragraph (and use {w}), or I need to be able to center yalign a block of text.
I have several voiced narration blocks like this, so the height will be different each time, meaning I can't tweak the padding to make it work (unless I make several nvl styles...)
Here is my text block:
Code: Select all
voice "voice/session1_line1.ogg"
n "This is my first line of dialogue which is a lot longer than the next two."
voice "voice/session1_line2.ogg"
n "This is the second line…{w=1.0}{nw}"
voice sustain
n "...which is split into another."
nvl clearCode: Select all
define gui.nvl_height = None
define gui.nvl_text_xpos = 0.5
define gui.nvl_text_ypos = 0.5Thank you in advance