Problems with Screen(Solved)

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
zabuzaeldemonio
Regular
Posts: 103
Joined: Sun Jan 08, 2017 7:24 pm
Projects: Call Me
Location: Spain
Contact:

Problems with Screen(Solved)

#1 Post by zabuzaeldemonio »

Greetings, I explain a little the situation, at a given time in the script I use:

Code: Select all

call screen menu
After this will show:

Code: Select all

screen menugame:
    

    add "gui/Inicio/iniciooscuro.jpg" 
    
    imagebutton auto "gui/Inicio/masculino_%s.png" xpos 0 ypos 0 focus_mask True action ShowMenu("seguro") activate_sound ("musica/menu/Blip2.wav") hovered [ Play ("test_alz3", "sfx/click.wav") ]
    imagebutton auto "gui/Inicio/femenino_%s.png" xpos 1130 ypos 0 focus_mask True action ShowMenu("seguro2") activate_sound ("musica/menu/Blip2.wav") hovered [ Play ("test_alz3", "sfx/click.wav") ]

screen seguro:
    

    add "gui/Inicio/iniciooscuro.jpg"
    use menugame
    imagebutton auto "gui/Inicio/simmas_%s.png" xpos 820 ypos 250 focus_mask
    imagebutton auto "gui/Inicio/sure_%s.png" xpos 700 ypos 550 focus_mask
    
    imagebutton auto "gui/Inicio/si_%s.png" xpos 730 ypos 750 focus_mask True action SetVariable("hombre", "True"), Jump("next") activate_sound ("musica/menu/Blip2.wav") hovered [ Play ("test_alz3", "sfx/click.wav") ]
    imagebutton auto "gui/Inicio/no_%s.png" xpos 1030 ypos 750 focus_mask True action ShowMenu("menu") activate_sound ("musica/menu/Blip2.wav") hovered [ Play ("test_alz3", "sfx/click.wav") ]
My intention is to give the player two buttons, one of them will activate a variable and use a jump, but once you have made the jump the previous screen does not finish going, I would like to know a way to remove this screen once the player selects a button.

Thank you very much.
Last edited by zabuzaeldemonio on Mon Feb 26, 2018 9:11 pm, edited 2 times in total.
My personal Project:
Image

irredeemable
Regular
Posts: 78
Joined: Thu Feb 08, 2018 7:57 am
Contact:

Re: Problems with Screen

#2 Post by irredeemable »

You're including it with the line 'use menu.' Remove that line. You also probably don't want to name your screen 'menu' (not sure if it will cause issues, but it's the tag used by the game menus), and change the ShowMenu actions to Show.

zabuzaeldemonio
Regular
Posts: 103
Joined: Sun Jan 08, 2017 7:24 pm
Projects: Call Me
Location: Spain
Contact:

Re: Problems with Screen

#3 Post by zabuzaeldemonio »

No, I've done that and it's still the same, the screen remains
My personal Project:
Image

irredeemable
Regular
Posts: 78
Joined: Thu Feb 08, 2018 7:57 am
Contact:

Re: Problems with Screen

#4 Post by irredeemable »

Give them both the same tag, add something like:

Code: Select all

tag myscreen
to each.

zabuzaeldemonio
Regular
Posts: 103
Joined: Sun Jan 08, 2017 7:24 pm
Projects: Call Me
Location: Spain
Contact:

Re: Problems with Screen

#5 Post by zabuzaeldemonio »

Still the same, maybe I should comment a bit on what happens when the player hits the button; once you select it, the screen remains in the background while the dialogue continues, even if you cover it with some scene background, when you right click you can still see this screen.
My personal Project:
Image

zabuzaeldemonio
Regular
Posts: 103
Joined: Sun Jan 08, 2017 7:24 pm
Projects: Call Me
Location: Spain
Contact:

Re: Problems with Screen

#6 Post by zabuzaeldemonio »

Wait, I did not know that I had to combine the two things you told me, with the menugame tag, and changing ShowMenu for Show, it works, thank you very much for the help.
My personal Project:
Image

Post Reply

Who is online

Users browsing this forum: Bing [Bot]