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.
-
Keinart
- Regular
- Posts: 133
- Joined: Sun May 13, 2012 8:28 pm
- Completed: One Thousand Lies
- Projects: Lotus Reverie
- Organization: Keinart Lobre
- Tumblr: keinart
- itch: keinart
- Location: Spain
-
Contact:
#1
Post
by Keinart » Fri Jan 17, 2014 9:54 pm
I changed the Yes/No Prompt background to a transparent one so the screen gets darker when the message appears. It works fine except when pressing the X in windows mode to exit just as you can see in the picture. Is there anyway to change this?
Basically I want to see how the screen gets darker instead of changing completly, no matter if I'm in the middle of the novel or in any menu.
Thanks in advance.
-
Crazy Li
- Regular
- Posts: 113
- Joined: Fri Jan 03, 2014 3:35 pm
-
Contact:
#2
Post
by Crazy Li » Sat Jan 18, 2014 4:38 am
You're lucky. In Ren'py 6.16, clicking the 'X' there just gives me an error message (regular quitting works fine though). At least you can click it without crashing your game. I suspect something changed in newer versions of Ren'py that made clicking the 'X' call the screen differently than activating "Quit()" because in the version I first got (6.13), it didn't have that error message problem. Clicking the 'X' functioned 100% the same as Quitting in any other fashion. It also did the darker message thing that you wanted perfectly fine for me.
I often find that when the background changes like that, it's an issue with the fact that it's a menu. When Ren'py calls a menu, it calls it as a brand new screen, erasing any other open menus (including the main menu). If you try for a transparent BG, you'll end up getting that checkerboard behind it because there is no background under your new menu. Sometimes even with simple prompts, it can get confused and resort to this behavior. Without re-doing the way the screens function significantly, you pretty much can't see anything behind a menu unless the only thing under it was the game itself. If you go from a menu to another menu, you lose that game behind it effect.
-
DesertFox
- Regular
- Posts: 196
- Joined: Sun Jul 28, 2013 1:29 pm
- Completed: Over The Hills And Far Away
- Projects: My Little Dictator
- Organization: WarGirl Games
-
Contact:
#3
Post
by DesertFox » Sat Jan 18, 2014 8:02 am
If you go to screens.rpy and to your Yes/No prompt section you'll see:
Code: Select all
screen yesno_prompt:
tag menu
modal True
The line 'tag menu' means that this screen will replace other screens instead of just overlay them. So just comment with a # or remove it.
Code: Select all
screen yesno_prompt:
#tag menu
modal True
-
Keinart
- Regular
- Posts: 133
- Joined: Sun May 13, 2012 8:28 pm
- Completed: One Thousand Lies
- Projects: Lotus Reverie
- Organization: Keinart Lobre
- Tumblr: keinart
- itch: keinart
- Location: Spain
-
Contact:
#4
Post
by Keinart » Sat Jan 18, 2014 12:34 pm
DesertFox wrote:If you go to screens.rpy and to your Yes/No prompt section you'll see:
Code: Select all
screen yesno_prompt:
tag menu
modal True
The line 'tag menu' means that this screen will replace other screens instead of just overlay them. So just comment with a # or remove it.
Code: Select all
screen yesno_prompt:
#tag menu
modal True
Thanks for replying.
I tried this but it doesn't seem to work, and I haven't made any changes on the code for the Yes/No Prompt so I don't really think I messed anywhere

In fact, in any other menu or part of the game, it seems to work fine, it only changes the background completly when I press the X to exit. Pics related:
Crazy Li wrote:You're lucky. In Ren'py 6.16, clicking the 'X' there just gives me an error message (regular quitting works fine though). At least you can click it without crashing your game. I suspect something changed in newer versions of Ren'py that made clicking the 'X' call the screen differently than activating "Quit()" because in the version I first got (6.13), it didn't have that error message problem. Clicking the 'X' functioned 100% the same as Quitting in any other fashion. It also did the darker message thing that you wanted perfectly fine for me.
I often find that when the background changes like that, it's an issue with the fact that it's a menu. When Ren'py calls a menu, it calls it as a brand new screen, erasing any other open menus (including the main menu). If you try for a transparent BG, you'll end up getting that checkerboard behind it because there is no background under your new menu. Sometimes even with simple prompts, it can get confused and resort to this behavior. Without re-doing the way the screens function significantly, you pretty much can't see anything behind a menu unless the only thing under it was the game itself. If you go from a menu to another menu, you lose that game behind it effect.
So, maybe it's something related with the new version? I just updated to it so maybe is related
-
Crazy Li
- Regular
- Posts: 113
- Joined: Fri Jan 03, 2014 3:35 pm
-
Contact:
#5
Post
by Crazy Li » Sat Jan 18, 2014 3:17 pm
So only yes/no when you click the X? If you click your "Salir" button, that yes/no prompt works right? If that's the case, I really do suspect the version is the culprit.
-
Keinart
- Regular
- Posts: 133
- Joined: Sun May 13, 2012 8:28 pm
- Completed: One Thousand Lies
- Projects: Lotus Reverie
- Organization: Keinart Lobre
- Tumblr: keinart
- itch: keinart
- Location: Spain
-
Contact:
#6
Post
by Keinart » Sat Jan 18, 2014 4:11 pm
Crazy Li wrote:So only yes/no when you click the X? If you click your "Salir" button, that yes/no prompt works right? If that's the case, I really do suspect the version is the culprit.
Exactly, if I press "Salir" it works fine. It doesn't really make any sense

-
Crazy Li
- Regular
- Posts: 113
- Joined: Fri Jan 03, 2014 3:35 pm
-
Contact:
#7
Post
by Crazy Li » Sun Jan 19, 2014 4:21 am
Yep, that's my problem. Except worse because it won't even show the yes/no prompt, instead just giving me an error message. Something about overlays or something. I just stick to my older version because it works without errors.
-
Pierrou
- Regular
- Posts: 53
- Joined: Fri Dec 05, 2014 8:25 pm
- Projects: Togainu no Chi, DMMD, Omerta, ...
- Skype: pierrouney
- Location: France
-
Contact:
#8
Post
by Pierrou » Wed Jan 21, 2015 12:26 am
I have the same problem... It works fine everywhere but not when i click on the "Red X" :/
Exactly the same bug...
Does anyone know why ?
I'm on Mac OS X Yosemite // Ren'Py 6.18.3
Sorry for my english, it's not my native language. :s
-
OokamiKasumi
- Eileen-Class Veteran
- Posts: 1779
- Joined: Thu Oct 14, 2010 3:53 am
- Completed: 14 games released -- and Counting.
- Organization: DarkErotica Games
- Deviantart: OokamiKasumi
- Location: NC, USA
-
Contact:
#9
Post
by OokamiKasumi » Wed Jan 21, 2015 4:26 am
Have you tried this solution?
http://lemmasoft.renai.us/forums/viewto ... 21#p343438
Though this is normally used with an Imagemap it can be adapted by adding just this to the Top:
Code: Select all
# Yes/No Prompt
screen yesno_prompt(message, yes_action, no_action):
modal True
# window:
# style "gm_root"
if message == layout.QUIT:
if main_menu:
add "background.jpg"
However, this adds a background to ALL the Quit screens, (and
only the Quit screens.)
Ookami Kasumi ~ Purveyor of fine Smut.
Most recent Games Completed:
For ALL my completed games visit:
DarkErotica Games
"
No amount of great animation will save a bad story." --
John Lasseter of
Pixar
-
Yuuji
- Regular
- Posts: 96
- Joined: Tue Jan 20, 2015 3:08 am
- Location: Russia, Perm
-
Contact:
#10
Post
by Yuuji » Wed Jan 21, 2015 4:37 am
But what should I do if I want previous background to stay without changes? Yes/no prompt should appear in front of all layers, right?(modal True) Why this screen clears all layers behind it in case of "red x" click?
-
xela
- Lemma-Class Veteran
- Posts: 2481
- Joined: Sun Sep 18, 2011 10:13 am
-
Contact:
#11
Post
by xela » Wed Jan 21, 2015 6:59 am
It's like
dejavu from 10 days ago...
Like what we're doing? Support us at:

-
shivanshs9
- Regular
- Posts: 54
- Joined: Sun Jul 20, 2014 1:59 pm
- Projects: The Destiny(http://thedestiny-cxz.blogspot.com)
- Organization: Cyber-X-Zone
- Location: India
-
Contact:
#12
Post
by shivanshs9 » Wed Jan 21, 2015 7:23 am
Just like what xela suggested...
In the Ren'Py documentation:
config.quit_action
First, use the bit of code as DesertFox suggested and then add this in options.rpy under init python...
Code: Select all
init python:
config.quit_action = Quit()
And, it's done!
"Destiny is a no matter of chance
It is a matter of choice
It is not a thing to be waited for
It is a thing to be achieved..."
-William Jennings Bryan
If you can dream and not make dreams your master;
If you can think and not make thoughts your aim,
If you can meet with Triumph and Disaster;
And treat those two impostors just the same,
Only then can you ever win against yourself...
-
Yuuji
- Regular
- Posts: 96
- Joined: Tue Jan 20, 2015 3:08 am
- Location: Russia, Perm
-
Contact:
#13
Post
by Yuuji » Wed Jan 21, 2015 7:45 am
Thank you very much!
-
Pierrou
- Regular
- Posts: 53
- Joined: Fri Dec 05, 2014 8:25 pm
- Projects: Togainu no Chi, DMMD, Omerta, ...
- Skype: pierrouney
- Location: France
-
Contact:
#14
Post
by Pierrou » Wed Jan 21, 2015 11:05 am
xela wrote:It's like
dejavu from 10 days ago...
Haaaa that Xela

I love you <3
Sorry for my english, it's not my native language. :s
Users browsing this forum: Bing [Bot], Google [Bot]