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.
Hi all. I want to create my own small console from the settings menu.
I created an "Open Console" button in the game settings, which opens the corresponding screen with Input and immediately provides the ability to enter text. The problem is that I don't know how to properly hook the result after pressing the Enter button. Also, after pressing the Enter button, the game automatically starts (the next iteration happens, as I understand it). How do I avoid this and just get the input string in the python code?
Interested only for mobile devices.
You are only showing the console screen, but you need to call it. You can scrap the function for toggling the screen completely, a called screen will hide when it returns something, which input does.
Crappy White Wings (currently quite inactive)
Working on: KANPEKI!
(On Hold: New Eden, Imperial Sea, Pure Light)
Milkymalk wrote: ↑Sun Apr 03, 2022 2:48 pm
You are only showing the console screen, but you need to call it.
Yep, you're right. Thank you, but I've already solved it through "renpy.show_screen" and executing the label with "renpy.call_in_new_context" for this.
I don't think my version is the short and proper solution either , but it works great.