[SOLVED] Removing background image in menu choices

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
User avatar
sasquatchii
Miko-Class Veteran
Posts: 551
Joined: Fri Jul 04, 2014 7:48 am
Completed: A Day in the Life of a Slice of Bread
Deviantart: sasquatchix
Soundcloud: sasquatchii
itch: sasquatchii
Location: South Carolina
Contact:

[SOLVED] Removing background image in menu choices

#1 Post by sasquatchii » Wed Dec 28, 2016 8:28 pm

I'm having trouble with customizing my menu choices for my game.

Here's what the menu choices currently look like:

Image

But the frustrating thing is the background behind it - I don't want that dark purple background behind the choices! Instead, I want this screen from my game (shown below) to show as well - this is what will be seen right before the menu choices, and I'd also like to have it there when the choices appear as well.

Image

Any ideas or thoughts on how I could fix this would be greatly appreciated!
Last edited by sasquatchii on Sun Jan 01, 2017 3:05 am, edited 2 times in total.
ImageImage

User avatar
Divona
Miko-Class Veteran
Posts: 678
Joined: Sun Jun 05, 2016 8:29 pm
Completed: The Falconers: Moonlight
Organization: Bionic Penguin
itch: bionicpenguin
Contact:

Re: Removing background image in menu choices

#2 Post by Divona » Thu Dec 29, 2016 12:39 am

Just put the text inside "menu" block to have them show together with choices.

Code: Select all

menu:
    "I'm in a small place. No way to get out."

    "Smell":
        jump action_smell

    "Look":
        jump action_look

    "Feel":
        jump action_feel

    "Move":
        jump action_move
Completed:
Image

User avatar
sasquatchii
Miko-Class Veteran
Posts: 551
Joined: Fri Jul 04, 2014 7:48 am
Completed: A Day in the Life of a Slice of Bread
Deviantart: sasquatchix
Soundcloud: sasquatchii
itch: sasquatchii
Location: South Carolina
Contact:

Re: Removing background image in menu choices

#3 Post by sasquatchii » Thu Dec 29, 2016 10:59 am

Thanks, Divona! I tried that and I'm getting this error message from Ren'Py:

Code: Select all

I'm sorry, but errors were detected in your script. Please correct the
errors listed below, and try again.


File "game/script.rpy", line 42: expected menuitem
    laika neutral "I'm in a small place. No way to get out."
    ^

Ren'Py Version: Ren'Py 6.99.10.1227
Here's what I currently have so far, any ideas on how I could fix it?

Code: Select all

label choices:

menu:
    laika neutral "I'm in a small place. No way to get out."
    
    "Smell":
        jump smell

    "Look":
        jump look

    "Feel":
        jump feel

    "Move":
        jump move

    label smell:
        show laika neutral "The room smells mostly like me."
        jump choices
    
    label look:
        laika neutral "The room smells mostly like me."
        jump choices
    
    label feel:
        laika neutral "The room smells mostly like me."
        jump choices    
    
    label move:
        laika neutral "The room smells mostly like me."
ImageImage

User avatar
SundownKid
Lemma-Class Veteran
Posts: 2299
Joined: Mon Feb 06, 2012 9:50 pm
Completed: Icebound, Selenon Rising Ep. 1-2
Projects: Selenon Rising Ep. 3-4
Organization: Fastermind Games
Deviantart: sundownkid
Location: NYC
Contact:

Re: Removing background image in menu choices

#4 Post by SundownKid » Thu Dec 29, 2016 1:15 pm

I would also de-indent the other labels and indent the menu one more.

If that doesnt work try removing the "laika neutral" from the text.

User avatar
sasquatchii
Miko-Class Veteran
Posts: 551
Joined: Fri Jul 04, 2014 7:48 am
Completed: A Day in the Life of a Slice of Bread
Deviantart: sasquatchix
Soundcloud: sasquatchii
itch: sasquatchii
Location: South Carolina
Contact:

Re: Removing background image in menu choices

#5 Post by sasquatchii » Thu Dec 29, 2016 2:43 pm

Thanks, SundownKid.

De-indenting worked, but having the side character portrait (for "Laika neutral") is giving me this error:

Code: Select all

I'm sorry, but errors were detected in your script. Please correct the
errors listed below, and try again.


File "game/script.rpy", line 44: expected menuitem
    laika neutral "I'm in a small place. No way to get out."
    ^

Ren'Py Version: Ren'Py 6.99.10.1227
Which is frustrating, because I definitely want the side character portrait there as well. Is there any work around for this error, or do I have to get rid of the side character portraits...?
ImageImage

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

Re: Removing background image in menu choices

#6 Post by Imperf3kt » Fri Dec 30, 2016 1:37 am

Here's what I would do:
At the top of script.rpy, before any labels or your splashscreen, presplash, etc.

Code: Select all

define ln = Character('laika neutral', image="laika_n")
image side laika_n = "laika neutral.png"
in your script

Code: Select all

label choices:
    
    menu:
        ln "I'm in a small place. No way to get out."
        "Smell":
            jump smell

        "Look":
            jump look

        "Feel":
            jump feel

        "Move":
            jump move
            
label smell:
    ln "The room smells mostly like me."
    jump choices
    
label look:
    ln "The room smells mostly like me."
    jump choices
    
label feel:
    ln "The room smells mostly like me."
    jump choices    
    
label move:
    ln "The room smells mostly like me."
The result? (after placing defined image in images folder)
screenshot0009.png
E: I just realised I made a small error.
I assume "neutral" is supposed to be a state, not the full character name.

In that case, use this instead:

Code: Select all

define ln = Character('laika', image="laika_n")
image side laika_n = "laika neutral.png"
I never really learnt how to define expressions, so I just define one per expression.

Code: Select all

define ln = Character('laika', image="laika_n")
image side laika_n = "laika neutral.png"
define la = Character('laika', image="laika_a")
image side laika_a = "laika angry.png"
etc...

User avatar
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: Removing background image in menu choices

#7 Post by PyTom » Fri Dec 30, 2016 3:33 am

Actually just leave the "neutral" out. The menu stuff isn't capable of dealing with it.
Supporting creators since 2004
(When was the last time you backed up your game?)
"Do good work." - Virgil Ivan "Gus" Grissom
"Silly and fun things are important." - Elon Musk
Software > Drama • https://www.patreon.com/renpytom

User avatar
sasquatchii
Miko-Class Veteran
Posts: 551
Joined: Fri Jul 04, 2014 7:48 am
Completed: A Day in the Life of a Slice of Bread
Deviantart: sasquatchix
Soundcloud: sasquatchii
itch: sasquatchii
Location: South Carolina
Contact:

Re: Removing background image in menu choices

#8 Post by sasquatchii » Sun Jan 01, 2017 2:17 am

It worked!!! Thank you, PyTom and Imperf3kt!
ImageImage

Post Reply

Who is online

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