Page 1 of 1
Fade to black when you start a new game?
Posted: Fri Mar 10, 2017 9:24 pm
by InvertMouse
Hi there

. When you call Start() to begin a new game, is it possible to make the menu slowly fade to black first? I have tried to set up the transition config here:
https://www.renpy.org/doc/html/config.html
But none of them seem to do the trick. Sorry for not knowing something so basic. I tried to look at the docs, and I searched the forums, but I wasn't able to find an answer. Chances are, I just failed to use the right keywords.
Thank you!
Re: Fade to black when you start a new game?
Posted: Fri Mar 10, 2017 11:31 pm
by indoneko
Renpy doesn't have any transition between the main menu and the beginning of a new game.
Re: Fade to black when you start a new game?
Posted: Fri Mar 10, 2017 11:47 pm
by Arowana
I think you can just write the transition when you begin your first scene. For example:
Code: Select all
label start:
scene school
with fade
"My first scene."
Re: Fade to black when you start a new game?
Posted: Sat Mar 11, 2017 3:22 am
by InvertMouse
Thank you for the responses

. Yeah, you can start the scene with fade, but the menu will still jump to black first without fading.
Re: Fade to black when you start a new game?
Posted: Sat Mar 11, 2017 4:07 am
by Arowana
Hmm, really? The menu fades smoothly for me without jumping. Or maybe I'm misunderstanding the effect you're looking for?
Re: Fade to black when you start a new game?
Posted: Sat Mar 11, 2017 4:24 am
by indoneko
@Invertmouse : if you're typing "scene black" and "with fade" on the same line, the result will be different from typing them on different lines. Arowana's code actually works; it emulates transition between main menu and new game (which by default isn't supported in renpy's config).
Re: Fade to black when you start a new game?
Posted: Sat Mar 11, 2017 5:35 am
by IrinaLazareva
Well...
For example, that is real screen of main menu (in screens.rpy)
Code: Select all
screen main_menu():
tag menu
window:
style "mm_root"
frame:
style_group "mm"
xalign .98
yalign .98
has vbox
textbutton _("Start Game") action Start()
textbutton _("Load Game") action ShowMenu("load")
textbutton _("Preferences") action ShowMenu("preferences")
textbutton _("Help") action Help()
textbutton _("Quit") action Quit(confirm=False)
then
Code: Select all
#fake screen of main menu (just copy)
screen notmain_menu():
tag menu
window:
style "mm_root"
frame:
style_group "mm"
xalign .98
yalign .98
has vbox
textbutton _("Start Game") action NullAction() #disabled (just in case)
textbutton _("Load Game") action NullAction()
textbutton _("Preferences") action NullAction()
textbutton _("Help") action NullAction()
textbutton _("Quit") action NullAction()
timer .1 action Hide("notmain_menu", transition=Fade(2, 0, 0)) ## add Transition
# The game starts here.
label start:
show screen notmain_menu
scene black
$ renpy.pause (3, hard=True)
"Hello"
return
Re: Fade to black when you start a new game?
Posted: Sat Mar 11, 2017 3:35 pm
by InvertMouse
Thanks again everyone

. indoneko, yes, your response works! I had no idea putting them on separate lines made a difference. Thank you.