How to show text while calling a screen?

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
ConerNSFW
Regular
Posts: 40
Joined: Sun Oct 23, 2016 5:08 pm
Contact:

How to show text while calling a screen?

#1 Post by ConerNSFW » Mon Nov 07, 2016 10:43 pm

I was wondering if there is any way to show text at the same time as calling a screen. I believe the problem is that renpy auto hides the last line of text when going onto the next line of code and this means that it hides the text then calls the screen.

I know that nvl doesn't have this issue since you have to hide nvl text with the 'nvl clear' command, but I can't really use that in my project.

The only other alternative is to have text built into the screen at the same position as the text-box, and if I have to do this, is there are advice for the best possible method?

User avatar
Divona
Miko-Class Veteran
Posts: 678
Joined: Sun Jun 05, 2016 8:29 pm
Completed: The Falconers: Moonlight
Organization: Bionic Penguin
itch: bionicpenguin
Contact:

Re: How to show text while calling a screen?

#2 Post by Divona » Mon Nov 07, 2016 11:45 pm

What about show screen before the text?

Code: Select all

show screen screen_name
"Hello World"
Completed:
Image

ConerNSFW
Regular
Posts: 40
Joined: Sun Oct 23, 2016 5:08 pm
Contact:

Re: How to show text while calling a screen?

#3 Post by ConerNSFW » Sun Nov 27, 2016 6:56 pm

I know this reply is very late, but that wouldn't work since I have to call the screen so it takes control.

User avatar
xela
Lemma-Class Veteran
Posts: 2481
Joined: Sun Sep 18, 2011 10:13 am
Contact:

Re: How to show text while calling a screen?

#4 Post by xela » Sun Nov 27, 2016 7:05 pm

Try:

Code: Select all

screen test():
    textbutton "Exit":
        align .5, .5
        action Return()

label start:
    $ renpy.say("", "Meow!", interact=False)
    call screen test
    "Meow x2!"
Like what we're doing? Support us at:
Image

ConerNSFW
Regular
Posts: 40
Joined: Sun Oct 23, 2016 5:08 pm
Contact:

Re: How to show text while calling a screen?

#5 Post by ConerNSFW » Thu Aug 24, 2017 7:47 am

Thanks that worked.

Post Reply

Who is online

Users browsing this forum: Google [Bot], Hojoo