Labels not being recognized

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
Katilinann
Newbie
Posts: 2
Joined: Thu Apr 20, 2017 5:42 pm
Contact:

Labels not being recognized

#1 Post by Katilinann »

Sorry if this is an incredibly dumb question, but I am very new to this. Either way, I have 5 different labels (3 options that lead into 2 other options for a total of 5 different labels); however, none of the labels are recognized. Here is the code

Code: Select all

R"So sorry!, I was standing in the way wasnt I..."
    "He scratched the back of his head with his free arm and handed you your last book."
    menu:
        "No, It was my fault I wasnt looking where I was going!":
            jump:bestrouteriley:
        "Yes, but I want playing attention":
            jump:okrouteriley:
        "Yeah, move":
            jump:worstrouteriley:
        
label bestrouteriley:
    R"If you say so but.. I was totally in the way"
    "He shrugs and lets out a goofy smile with his hand still behind his head"
    R"Would you like to walk with me to orientation?"
    menu:
        "Yeah sure!":
            jump:walk1riley
        "I'll make it on my own, but thanks!":
            jump:nowalk1riley
            
label okrouteriley:
    R"Sorry, I've got to learn crowded places"
    "He shrugs"
    menu:
        "Yeah sure!":
            jump:walk1riley
        "No thanks.":
            jump:nowalk1riley
            
label worstrouteriley:
    R"oh."
    "He quickly moves out of the way and walks into the building"
    jump:nowalk1riley

label nowalk1riley:
    "You began to walk down the hallway to the designated room number, Room A-39"
    
label walk1riley:
    R"Glad you could join me!"
    R"Im not really too sure how to navigate this huge bulding"
    "When he said huge both of his hands flung out to the side"
    Y"No problem, It should be around here since its a floor one room..."

User avatar
xavimat
Eileen-Class Veteran
Posts: 1461
Joined: Sat Feb 25, 2012 8:45 pm
Completed: Yeshua, Jesus Life, Cops&Robbers
Projects: Fear&Love
Organization: Pilgrim Creations
Github: xavi-mat
itch: pilgrimcreations
Location: Spain
Discord: xavimat
Contact:

Re: Labels not being recognized

#2 Post by xavimat »

mmmm. Why the colon (:) in the jump statement?
https://www.renpy.org/doc/html/label.ht ... -statement
Comunidad Ren'Py en español: ¡Únete a nuestro Discord!
Rhaier Kingdom A Ren'Py Multiplayer Adventure Visual Novel.
Cops&Robbers A two-player experiment | Fear&Love Why can't we say I love you?
Honest Critique (Avatar made with Chibi Maker by ~gen8)

jw2pfd
Regular
Posts: 87
Joined: Tue Sep 18, 2012 9:55 pm
Location: DFW, TX, USA
Contact:

Re: Labels not being recognized

#3 Post by jw2pfd »

Katilinann wrote:Sorry if this is an incredibly dumb question, but I am very new to this. Either way, I have 5 different labels (3 options that lead into 2 other options for a total of 5 different labels); however, none of the labels are recognized.
This is because of how the syntax should be. You are writing lines like this:

Code: Select all

            jump:bestrouteriley:
When it should look like this:

Code: Select all

            jump bestrouteriley
The syntax is such that it doesn't use colons like that in those statements. The corrected syntax for the code would be this code below; however, once it has no syntax errors and runs, you still need to make sure it does what you expect and want it to do:

Code: Select all

    R"So sorry!, I was standing in the way wasnt I..."
    "He scratched the back of his head with his free arm and handed you your last book."
    menu:
        "No, It was my fault I wasnt looking where I was going!":
            jump bestrouteriley
        "Yes, but I want playing attention":
            jump okrouteriley
        "Yeah, move":
            jump worstrouteriley
        
label bestrouteriley:
    R"If you say so but.. I was totally in the way"
    "He shrugs and lets out a goofy smile with his hand still behind his head"
    R"Would you like to walk with me to orientation?"
    menu:
        "Yeah sure!":
            jump walk1riley
        "I'll make it on my own, but thanks!":
            jump nowalk1riley
            
label okrouteriley:
    R"Sorry, I've got to learn crowded places"
    "He shrugs"
    menu:
        "Yeah sure!":
            jump walk1riley
        "No thanks.":
            jump nowalk1riley
            
label worstrouteriley:
    R"oh."
    "He quickly moves out of the way and walks into the building"
    jump nowalk1riley

label nowalk1riley:
    "You began to walk down the hallway to the designated room number, Room A-39"
    
label walk1riley:
    R"Glad you could join me!"
    R"Im not really too sure how to navigate this huge bulding"
    "When he said huge both of his hands flung out to the side"
    Y"No problem, It should be around here since its a floor one room..."

Katilinann
Newbie
Posts: 2
Joined: Thu Apr 20, 2017 5:42 pm
Contact:

Re: Labels not being recognized

#4 Post by Katilinann »

Thanks! It was so simple, the tutorial I was watching was formatted like that for some reason. Well, now i know. Thanks again!

Post Reply

Who is online

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