If you middle click or push the H button it will hide the user interface.
I want to add a button in my quick menu that will do the same thing, but I don't know how.
Is there a way to do this?
Screen action for hiding interface
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.
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.
- Dreadwing93
- Regular
- Posts: 30
- Joined: Mon May 20, 2013 1:44 am
- Projects: 0xE125: Crimson Spiral
- Contact:
- akemicchi
- Veteran
- Posts: 465
- Joined: Mon Dec 31, 2007 11:22 pm
- Projects: Magicians of Delphine, Panaderia: Ensaimada, SweetTooth!, XOXO Droplets
- Deviantart: littlebabyshoes
- Contact:
Re: Screen action for hiding interface
The line you want is renpy.curried_call_in_new_context("_hide_windows"), so on the quick menu screen, just place it after action.
If it's a textbutton, it'd be something like:
If it's a textbutton, it'd be something like:
Code: Select all
textbutton _("X") action renpy.curried_call_in_new_context("_hide_windows")- Dreadwing93
- Regular
- Posts: 30
- Joined: Mon May 20, 2013 1:44 am
- Projects: 0xE125: Crimson Spiral
- Contact:
- PyTom
- Ren'Py Creator
- Posts: 15893
- Joined: Mon Feb 02, 2004 10:58 am
- Completed: Moonlight Walks
- Projects: Ren'Py
- IRC Nick: renpytom
- Github: renpytom
- itch: renpytom
- Location: Kings Park, NY
- Contact:
Re: Screen action for hiding interface
As a completely stylistic thing, the best way to write this is probably:
It's a bit shorter, and more documented. (Not like I could ever substantially change _hide_windows.)
Code: Select all
textbutton _("X") action HideInterface()
Supporting creators since 2004
(When was the last time you backed up your game?)
"Do good work." - Virgil Ivan "Gus" Grissom(When was the last time you backed up your game?)
"Silly and fun things are important." - Elon Musk
Software > Drama • https://www.patreon.com/renpytom
Who is online
Users browsing this forum: _ticlock_


