invalid syntax

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
sunsrats
Newbie
Posts: 1
Joined: Sat Jan 09, 2021 6:13 am
Contact:

invalid syntax

#1 Post by sunsrats »

hii whenever i enter a code to help determine the players gender, i get a script failure telling me that the line a certain part is entered on is a invalid syntax.

also, keep in mind that im just copying a code another user had posted here! so im not quite sure the issue
define gender = 0
label start:

python:

menu choose_gender:
'What are your pronouns?'

"He/Him":
$ gender = "male"
"She/Her":
$ gender = "female"
"They/Them":
$ gender = "neutral"

show expression "mc_" + gender # show mc_male, mc_female, or mc_neutral
"Are you [gender]"?

menu:
"Yes":
"Okay."
"No":
jump choose_gender

"Next stuff."
that's what code i have, any help or clue what to do :@( ? i'm new at this so also let me know if you need more specifics

User avatar
chesarty
Regular
Posts: 116
Joined: Sat Aug 25, 2018 3:07 am
Completed: 0
Contact:

Re: invalid syntax

#2 Post by chesarty »

Which line is the invalid syntax error on?

P.S. I recommend putting your code inbetween [ccode] [/ccode] (one c in each lol) so we can see the indentations as well :)

User avatar
Remix
Eileen-Class Veteran
Posts: 1628
Joined: Tue May 30, 2017 6:10 am
Completed: None... yet (as I'm still looking for an artist)
Projects: An un-named anime based trainer game
Contact:

Re: invalid syntax

#3 Post by Remix »

Remove the

Code: Select all

    python:
line
Frameworks & Scriptlets:

Post Reply

Who is online

Users browsing this forum: No registered users