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.
-
Yuvan raj
- Regular
- Posts: 35
- Joined: Wed Feb 17, 2021 11:24 am
-
Contact:
#1
Post
by Yuvan raj » Thu May 27, 2021 12:07 pm
Hello, I'm using a modal True statement on a screen so that the game won't proceed and other buttons won't be clicked. But I want to make an exception to the modal True statement. I want the screen containing the buttons 'my stats, characters stats, skip time, etc' to be clickable.
This is what my game inside looks like. On the right side there are several buttons.
If I click one button this screen will pop up. I used modal True in this screen as I don't want the game to proceed when the player mistakenly click the sides. But I want the right side buttons to be interactable. I could put this modal true screen inside the button screen and use conditional statement to make it appear and also put the modal true statement the same condition so that when this screen appears the modal true statement will also run and can give me the result that I want. But I want to learn whether there is a way to make an expection for modal true or another way to accomplish what I want.

Thank you in advance.
-
laure44
- Regular
- Posts: 60
- Joined: Mon Mar 08, 2021 10:55 pm
- Projects: Arkan'sTower, Gemshine Lorelei!
- Location: France
-
Contact:
#2
Post
by laure44 » Thu May 27, 2021 7:29 pm
One way I can think of is putting the menu on the right in its own screen, then having the menu screen inside the other one with
use
This is how it works for the navigation menu (for exemple, save and load screens both use the navigation menu).
It would look like this:
Code: Select all
screen somemenu():
textbutton _("Button 1")
textbutton _("Button 2")
textbutton _("Button 3")
# etc
screen somescreen():
modal True
use somemenu
-
Yuvan raj
- Regular
- Posts: 35
- Joined: Wed Feb 17, 2021 11:24 am
-
Contact:
#3
Post
by Yuvan raj » Fri May 28, 2021 2:31 am
laure44 wrote: ↑Thu May 27, 2021 7:29 pm
One way I can think of is putting the menu on the right in its own screen, then having the menu screen inside the other one with
use
This is how it works for the navigation menu (for exemple, save and load screens both use the navigation menu).
It would look like this:
Code: Select all
screen somemenu():
textbutton _("Button 1")
textbutton _("Button 2")
textbutton _("Button 3")
# etc
screen somescreen():
modal True
use somemenu
Thank you! Your menthod was simpler than my 'condition' method. Only needed few edits. So I take it that there is no way to make an exception for the modat True statement? like a statment 'modal True except "some screen" '? But no problem I accomplished what I wanted. Thank you once again!