creating a "bonus/extra" menu with a playable script

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
sharksandwich
Newbie
Posts: 2
Joined: Wed Mar 20, 2024 1:34 pm
Contact:

creating a "bonus/extra" menu with a playable script

#1 Post by sharksandwich »

Hello ! (apologies for english, it's not my first language)

I would like to create an extra/bonus section in the menu. It could replace the "about" menu or something, whatever works honestly. I want the players to be able to access a playable part of the game.

Basically, I've never found long lists of credits at the end of the game to be useful when you want to know who created what, and I also want to include bonus content. So I would like the player to access a part where they could have choices that would lead them to what they are looking for (such as a choice like "what do you want to see?" and then another choice being "sound" option, and then accessing like "walking sound", "breaking glass sound", etc, that would be played and displayed with credits.)

I don't know if that's clear, but the idea is to having access to another playable part of the game from the menu, in which I would put credits and bonus content.
In the worst case scenario I'd have to put this at the beginning of the game, but I would rather give it a separate section.

I have no idea how to do that since I'm rather new to renpy, I tried to look on the internet but I couldn't find anything so I apologize if this question has already been answered.

User avatar
m_from_space
Miko-Class Veteran
Posts: 975
Joined: Sun Feb 21, 2021 3:36 am
Contact:

Re: creating a "bonus/extra" menu with a playable script

#2 Post by m_from_space »

sharksandwich wrote: Wed Mar 20, 2024 1:45 pm I would like to create an extra/bonus section in the menu. It could replace the "about" menu or something, whatever works honestly. I want the players to be able to access a playable part of the game.
It's hard to go over everything, since you say that you're new to Renpy. Just have a look inside <screens.rpy> and create your own screen.

Code: Select all

screen bonus_content():
    tag menu
    # insert everything the screen needs here
Then just add a link into the navigation screen:

Code: Select all

screen navigation():
    # ...
    textbutton "Bonus / Extra" action ShowMenu("bonus_content")
    # ...
sharksandwich wrote: Wed Mar 20, 2024 1:45 pm I don't know if that's clear, but the idea is to having access to another playable part of the game from the menu, in which I would put credits and bonus content.
In the worst case scenario I'd have to put this at the beginning of the game, but I would rather give it a separate section.
To access a specific label from the menu (which means starting a new game), you insert the following into your screen. Make sure that it's like the player starts a new game, so "default" variables are reset for that. Not sure what you have planned exactly, but this should give you an idea.

Code: Select all

screen bonus_content():
    tag menu
    textbutton "Start Bonus Content" action Start("bonus_label")
    # ...

label bonus_label:
    "Welcome to the bonus content..."
    # ...
    return

sharksandwich
Newbie
Posts: 2
Joined: Wed Mar 20, 2024 1:34 pm
Contact:

Re: creating a "bonus/extra" menu with a playable script

#3 Post by sharksandwich »

Thank you, that was clear and easy! It works very well.

Post Reply

Who is online

Users browsing this forum: Bing [Bot]