Narrator custom textbox issue with switching scenes

Discuss how to use the Ren'Py engine to create visual novels and story-based games. New releases are announced in this section.
Forum rules
This is the right place for Ren'Py help. Please ask one question per thread, use a descriptive subject like 'NotFound error in option.rpy' , and include all the relevant information - especially any relevant code and traceback messages. Use the code tag to format scripts.
Post Reply
Message
Author
User avatar
chesarty
Regular
Posts: 116
Joined: Sat Aug 25, 2018 3:07 am
Completed: 0
Contact:

Narrator custom textbox issue with switching scenes

#1 Post by chesarty » Sat Jan 23, 2021 11:25 am

I have two separate textboxes, one of the characters and one for narration. The issue is that when I switch to a new scene and Renpy loads in the textbox, the default (character) textbox shows up for a split second before it turns into the narrator one. It's not a huge problem and it works how it's programmed to, but it's just a bit ugly-looking seeing the other textbox before the one I want shown. Is there a way to fix it?

On a similar note, I have the scene where the player inputs their name and I want the textbox in that to be the narrator textbox instead of the character one. How do I do that?

Here's the input code:

Code: Select all

screen input(prompt):
    style_prefix "input"

    window:


        vbox:
            xalign gui.dialogue_text_xalign
            xpos gui.dialogue_xpos
            xsize gui.dialogue_width
            ypos gui.dialogue_ypos

            text prompt style "input_prompt"
            input id "input"
            input length 10
            input caret "blink"
            



style input_prompt is default

style input_prompt:
    xalign gui.dialogue_text_xalign
    properties gui.text_properties("input_prompt")

style input:
    xalign gui.dialogue_text_xalign
    xmaximum gui.dialogue_width

Code: Select all

    $ name = renpy.input("{i}I'm not an idiot! My name is...{/i}", length=10)
    $ name = name.strip()
    if name == "":
        $ name="Izumi"

User avatar
_ticlock_
Veteran
Posts: 393
Joined: Mon Oct 26, 2020 5:41 pm
Contact:

Re: Narrator custom textbox issue with switching scenes

#2 Post by _ticlock_ » Sat Jan 23, 2021 4:07 pm

Hi, chesarty,

Possibly this can help, although l am not sure if there is a better way to do it.

User avatar
chesarty
Regular
Posts: 116
Joined: Sat Aug 25, 2018 3:07 am
Completed: 0
Contact:

Re: Narrator custom textbox issue with switching scenes

#3 Post by chesarty » Sun Jan 24, 2021 7:41 am

_ticlock_ wrote:
Sat Jan 23, 2021 4:07 pm
Hi, chesarty,

Possibly this can help, although l am not sure if there is a better way to do it.
Thank you! That fixed the problem! :) The only issue now is the fact that that also gets rid of the textbox when there is an input screen...

Post Reply

Who is online

Users browsing this forum: Bing [Bot]