[Solved] Disconnecting History from Game Menu

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.
Post Reply
Message
Author
quinnelope
Newbie
Posts: 5
Joined: Sun Jul 30, 2017 6:44 pm
Contact:

[Solved] Disconnecting History from Game Menu

#1 Post by quinnelope »

I am new to screens, and wanted to start out by editing the default "History" screen to better fit my game. Part of that includes removing the game menu from the left side. I want the player to be able to open the history, read it if they want, then go back to the game.

I think it has something to do with

Code: Select all

    use game_menu(_("History"), scroll=("vpgrid" if gui.history_height else "viewport")):
(line 887 in the default screens.rpy)

I've tried commenting it out, but then nothing appears (and the only way to get out is to uncomment the line and shift+R). Then I tried deleting everything up to the comma, but then I got a syntax error. Do I have to make a new type of menu? Do I have to move the "scroll" part? Should I just comment out the whole history menu and make a new one from scratch?
Last edited by quinnelope on Fri Aug 10, 2018 2:07 pm, edited 1 time in total.

User avatar
MaydohMaydoh
Regular
Posts: 165
Joined: Mon Jul 09, 2018 5:49 am
Projects: Fuwa Fuwa Panic
Tumblr: maydohmaydoh
Location: The Satellite of Love
Contact:

Re: Disconnecting History from Game Menu

#2 Post by MaydohMaydoh »

In the game_menu screen there's a line

Code: Select all

use navigation
Put it in an if statement checking if the screen is history screen

Code: Select all

if title != "History":
    use navigation
Should hide the menu.

User avatar
Imperf3kt
Lemma-Class Veteran
Posts: 3791
Joined: Mon Dec 14, 2015 5:05 am
itch: Imperf3kt
Location: Your monitor
Contact:

Re: Disconnecting History from Game Menu

#3 Post by Imperf3kt »

MaydohMaydoh wrote: Thu Aug 09, 2018 6:58 pm In the game_menu screen there's a line

Code: Select all

use navigation
Put it in an if statement checking if the screen is history screen

Code: Select all

if title != "History":
    use navigation
Should hide the menu.
Since the navigation includes the only way to get out of the history screen, I recommend adding an exit/close/return button to the history screen itself.
Warning: May contain trace amounts of gratuitous plot.
pro·gram·mer (noun) An organism capable of converting caffeine into code.

Current project: GGD Mentor

Twitter

philat
Eileen-Class Veteran
Posts: 1909
Joined: Wed Dec 04, 2013 12:33 pm
Contact:

Re: Disconnecting History from Game Menu

#4 Post by philat »


quinnelope
Newbie
Posts: 5
Joined: Sun Jul 30, 2017 6:44 pm
Contact:

Re: [Solved] Disconnecting History from Game Menu

#5 Post by quinnelope »

Thank you all for your help!

Post Reply

Who is online

Users browsing this forum: Andredron, Bing [Bot], Google [Bot]