I honestly don't see my mistake from reading this. If anyone has run into these errors before, please just point out how to correct these annoying things. Hampering progress.I'm sorry, but errors were detected in your script. Please correct the
errors listed below, and try again.
On line 64 of C:\Users\xxx\Documents\Downloads\renpy-6.8.1\My Fatal Flower/game/script.rpy: say statement does not expect a block. Please check the indentation of the line after this one.
"We will forget about the kids, they are fine and lets just enjoy our selves."
^
On line 93 of C:\Users\xxx\Documents\Downloads\renpy-6.8.1\My Fatal Flower/game/script.rpy: end of line expected.
"So this is her sister i wounder what she is going to do to me or worse what is happening to my sister!" "Curse my self for being weak" "What are they any way?"
^
On line 94 of C:\Users\xxx\Documents\Downloads\renpy-6.8.1\My Fatal Flower/game/script.rpy: end of line expected.
"Tomoko aproaches cautionsly" " She looks more beautful then her sister.... as i lose my self in her eyes and gave at her body." "Hi boy, what is youre name?"
^
On line 108 of C:\Users\xxx\Documents\Downloads\renpy-6.8.1\My Fatal Flower/game/script.rpy: say statement does not expect a block. Please check the indentation of the line after this one.
"What should i do?"
^
On line 118 of C:\Users\xxx\Documents\Downloads\renpy-6.8.1\My Fatal Flower/game/script.rpy: say statement does not expect a block. Please check the indentation of the line after this one.
"As you step out..."
^
On line 126 of C:\Users\xxx\Documents\Downloads\renpy-6.8.1\My Fatal Flower/game/script.rpy: menu statement expects a non-empty block.
menu:
^
On line 127 of C:\Users\xxx\Documents\Downloads\renpy-6.8.1\My Fatal Flower/game/script.rpy: say statement does not expect a block. Please check the indentation of the line after this one.
"Clean."
^
On line 129 of C:\Users\xxx\Documents\Downloads\renpy-6.8.1\My Fatal Flower/game/script.rpy: say statement does not expect a block. Please check the indentation of the line after this one.
"Explore the house."
^
Ren'Py Version: Ren'Py 6.8.1a
Error text, end of line expected etc... What is wrong?
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.
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.
-
- Regular
- Posts: 48
- Joined: Mon Dec 10, 2007 4:41 pm
- Contact:
Error text, end of line expected etc... What is wrong?
Last edited by Air-Dragon on Fri Jan 09, 2009 12:00 am, edited 1 time in total.
Out researching with Jiraiya.
Re: Error text, end of line expected etc... What is wrong?
"say statement does not expect a block. Please check the indentation of the line after this one."
- means that most likely the line after the indicated one has been indented too much. Delete spaces from the front of it until it lines up with the above line.
"end of line expected."
- I think it wants you to place each section of text on a seperate line; so instead of
"So this is her sister i wounder what she is going to do to me or worse what is happening to my sister!" "Curse my self for being weak" "What are they any way?"
you need
"So this is her sister. I wonder what she is going to do to me; or, worse, what is happening to my sister!"
"Curse myself for being weak."
"What are they anyway?"
"menu statement expects a non-empty block."
- means your menu needs something in it.
- means that most likely the line after the indicated one has been indented too much. Delete spaces from the front of it until it lines up with the above line.
"end of line expected."
- I think it wants you to place each section of text on a seperate line; so instead of
"So this is her sister i wounder what she is going to do to me or worse what is happening to my sister!" "Curse my self for being weak" "What are they any way?"
you need
"So this is her sister. I wonder what she is going to do to me; or, worse, what is happening to my sister!"
"Curse myself for being weak."
"What are they anyway?"
"menu statement expects a non-empty block."
- means your menu needs something in it.
Re: Error text, end of line expected etc... What is wrong?
I'm 99% sure that all those "say statement does not expect a block. Please check the indentation of the line after this one." errors are because you did your menus wrong.
This is how to make a branching choice:
This is how to make a branching choice:
so what you probably need is something like (on line 108):PyTom wrote:Code: Select all
menu: "Question One: What is 2+2?": "4": $ corrects += 1 "5": $ corrects += 0
Code: Select all
menu:
"What should I do?"
"Take X action":
jump X
"Take Y action":
jump Y
-
- Regular
- Posts: 48
- Joined: Mon Dec 10, 2007 4:41 pm
- Contact:
Re: Error text, end of line expected etc... What is wrong?
Thank you Showsni and thank you Dusty for your help.
Out researching with Jiraiya.
-
- Newbie
- Posts: 1
- Joined: Tue Dec 18, 2018 7:14 pm
- Contact:
Re: Error text, end of line expected etc... What is wrong?
I keep getting an end of line error it looks like this: File "game/script.rpy line 18: end of line expected.
b "I love this wouldn't change it for anything"
with script looking like this:
label start:
a "I am sticking to something simple"
b "I know this is ridiculous"
a "How do you feel about all this?"
menu:
b "I love this. I wouldn't trade it for anything":
jump Ilovet
b "I hate this":
jump Ihatet
label Ilovet:
a "You are weird"
return
label Ihatet:
a "Yeah me, too"
return
I can't figure out what's wrong?
b "I love this wouldn't change it for anything"
with script looking like this:
label start:
a "I am sticking to something simple"
b "I know this is ridiculous"
a "How do you feel about all this?"
menu:
b "I love this. I wouldn't trade it for anything":
jump Ilovet
b "I hate this":
jump Ihatet
label Ilovet:
a "You are weird"
return
label Ihatet:
a "Yeah me, too"
return
I can't figure out what's wrong?
- 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: Error text, end of line expected etc... What is wrong?
Firstly, menu choices cannot have a character speaking them...
Secondly, you will find it far more readable if you un-indent all labels back to zero.
Thirdly, a prior post had a menu caption with a colon at the end ( "Question One: What is 2+2?": ) which is wrong.
So:
Lastly, when posting code in the forum, please put it in code block
[code]
Your code here
[/code]
Secondly, you will find it far more readable if you un-indent all labels back to zero.
Thirdly, a prior post had a menu caption with a colon at the end ( "Question One: What is 2+2?": ) which is wrong.
So:
Code: Select all
label start:
a "I am sticking to something simple"
b "I know this is ridiculous"
a "How do you feel about all this?"
menu:
"I love this. I wouldn't trade it for anything":
jump Ilovet
"I hate this":
jump Ihatet
label Ilovet:
a "You are weird"
return
label Ihatet:
a "Yeah me, too"
return
[code]
Your code here
[/code]
Frameworks & Scriptlets:
- Speech Bubble dialogue system
- Multiple Notify with ATL and history
- (WIP) Radial Masking - needs updating to use Shader
- 7.4 - Smooth Tinting using ATL and matrixcolor
- Several other repositories there too
-
- Newbie
- Posts: 5
- Joined: Wed Dec 03, 2014 11:02 pm
- Projects: Tutorials, Stock Images, Resources for Visual Novelty
- Tumblr: Vixeria
- Deviantart: Vixeria
- Skype: Vixeria
- itch: vixeria
- Location: USA
- Contact:
Re: Error text, end of line expected etc... What is wrong?
I'm also having a similar problem.... and I can't quite figure out what's happening.
I'm attempting to make a character selection map using a screen imagebutton and I'm failing pretty miserably. If someone could help me out, that'd be awesome.
So here's my error:
Here's the screen I made in the "screen.rpy" file:
....and here is my "script.rpy" file:
I've tried multiple variations such as renaming, removing colons, removing parenthesis, adding parenthesis, adding colons, etc. No matter combination I use, I keep getting the same error, and if I remove them altogether, I get an enormous error list. I would seriously appreciate it if someone could point out what the heck I'm doing wrong. :/ The lines that say "hide screen charaselect" are my problem lines that I've done the combos on.
I'm attempting to make a character selection map using a screen imagebutton and I'm failing pretty miserably. If someone could help me out, that'd be awesome.
So here's my 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 15: end of line expected.
hide screen charaselect() :
^
File "game/script.rpy", line 28: end of line expected.
hide screen charaselect() :
^
Ren'Py Version: Ren'Py 7.2.1.457
Fri Mar 22 16:02:00 2019
Code: Select all
###################### Chara Selection ################################
# This is an example code used to create a character selection screen.
# First, define a screen - name it whatever you want. I named this one "charaselect".
screen charaselect():
tag charaselect # Names the menu so that it doesn't create multiples.
modal True # This forces the game to pause to allow the player to select a choice.
add chara_bg # You don't have to add a backround if you don't want to.
# These are your image buttons.
imagebutton:
idle "images/2B_Default.png"
hover "images/2B_Hover.png"
xalign 0.2 yalign 0.5
focus_mask True
action Jump('sample1')
imagebutton:
idle "images/Ahri_Default.png"
hover "images/Ahri_Hover.png"
xalign 0.2 yalign 0.5
focus_mask True
action Jump('sample2')
Code: Select all
# The script of the game goes in this file.
# Go ahead and declare your characters. Note: Do not use numbers - it glitches.
define A = Character("2B", image= "chara1")
define B = Character("Ahri", image= "chara2")
# The game starts here.
label start:
scene chara_bg # Your background.
show screen charaselect() # Shows the chara selection that was made in the "screens.rpy" file.
label sample1: # This is where chara1 will start.
hide screen charaselect()
show chara1: # Shows chara image.
xalign 0.2 yalign 0.5 # Position of the chara image.
A "Congratulations are in order."
A "You have successfully chosen me as the start of your adventure. How do you feel?"
jump ending
return # Ends game.
label sample2:
hide screen charaselect()
show chara2: # Shows chara image.
xalign 0.2 yalign 0.5 # Position of the chara image.
B "Glad you made it this far, Brave Adventurer."
B "Now get moving and create your own chara selection screen!"
jump ending
return # Ends game.
- 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: Error text, end of line expected etc... What is wrong?
Code: Select all
label start:
scene chara_bg # Your background.
show screen charaselect() # Shows the chara selection that was made in the "screens.rpy" file. # actually no need to add the () here unless passing arguments
label sample1: # This is where chara1 will start. # un-indented back to the fold
hide screen charaselect # never use () on hide
show chara1: # Shows chara image.
xalign 0.2 yalign 0.5 # Position of the chara image.
A "Congratulations are in order."
A "You have successfully chosen me as the start of your adventure. How do you feel?"
jump ending
return # Ends game.
label sample2: # un-indented back to the fold again
hide screen charaselect # no ()
show chara2: # Shows chara image.
xalign 0.2 yalign 0.5 # Position of the chara image.
B "Glad you made it this far, Brave Adventurer."
B "Now get moving and create your own chara selection screen!"
jump ending
return # Ends game.
Frameworks & Scriptlets:
- Speech Bubble dialogue system
- Multiple Notify with ATL and history
- (WIP) Radial Masking - needs updating to use Shader
- 7.4 - Smooth Tinting using ATL and matrixcolor
- Several other repositories there too
Who is online
Users browsing this forum: Ahrefs [Bot]