renpy/doc/cookbook/Showing and Hiding the Window
From Ren'Py Visual Novel Engine
Showing and Hiding the Window
This recipe lets you show and hide the window. When the window is show, it will always be shown, even during transitions. When it is hidden, transitions will occur without the window on the screen. (But note that if dialogue is shown with the window hidden, it will be shown during the dialogue.)
init python: show_window_trans = MoveTransition(0.25, enter_factory=MoveIn((None, 1.0, None, 0.0))) hide_window_trans = MoveTransition(0.25, leave_factory=MoveOut((None, 1.0, None, 0.0))) def hide_window(): store._window_during_transitions = False narrator("", interact=False) renpy.with_statement(None) renpy.with_statement(hide_window_trans) def show_window(): narrator("", interact=False) renpy.with_statement(show_window_trans) store._window_during_transitions = True
Use it like:
e "Let's go somewhere else!" $ hide_window() scene bg somewhere else with dissolve $ show_window() e "We're here!"
You can change show_window_trans and hide_window_trans to change the effects that are used to show and hide the window.
