Expected 'image_name_component' not found -error?

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
chesarty
Regular
Posts: 116
Joined: Sat Aug 25, 2018 3:07 am
Completed: 0
Contact:

Expected 'image_name_component' not found -error?

#1 Post by chesarty »

I feel like a dumbass since this is probably a simple fix but I can't for the life of me figure out what this error message is trying to tell me.

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: expected 'image_name_component' not found.
    show "popup.png" with moveinbottom
         ^

File "game/script.rpy", line 20: expected 'image_name_component' not found.
    hide "popup.png" with moveoutbottom
         ^

Ren'Py Version: Ren'Py 7.3.2.320
Sun Aug 18 03:09:54 2019
Does it mean it can't find the popup.png? I already defined the popup.png and I'm pretty sure I did it correct. How in the heavens do I get it to work???

User avatar
isobellesophia
Miko-Class Veteran
Posts: 979
Joined: Mon Jan 07, 2019 2:55 am
Completed: None
Projects: Maddox and Friends! (AI Teacher friend), Friendly Universities! (Soon)
Organization: Friendly Teachers series
Deviantart: SophBelle
itch: Child Creation
Location: Philippines, Mindanao
Contact:

Re: Expected 'image_name_component' not found -error?

#2 Post by isobellesophia »

Can you show how do you define the image?
I am a friendly user, please respect and have a good day.


Image

Image


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

Re: Expected 'image_name_component' not found -error?

#3 Post by chesarty »

isobellesophia wrote: Sat Aug 17, 2019 9:46 pm Can you show how do you define the image?
I define it with a simple

Code: Select all

image popup="game/images/popup.png"
I've also tried various other ways to define it, using an init, not using it, trying all sorts of stuff. D:

User avatar
isobellesophia
Miko-Class Veteran
Posts: 979
Joined: Mon Jan 07, 2019 2:55 am
Completed: None
Projects: Maddox and Friends! (AI Teacher friend), Friendly Universities! (Soon)
Organization: Friendly Teachers series
Deviantart: SophBelle
itch: Child Creation
Location: Philippines, Mindanao
Contact:

Re: Expected 'image_name_component' not found -error?

#4 Post by isobellesophia »

chesarty wrote: Sat Aug 17, 2019 11:22 pm
isobellesophia wrote: Sat Aug 17, 2019 9:46 pm Can you show how do you define the image?
I define it with a simple

Code: Select all

image popup="game/images/popup.png"
I've also tried various other ways to define it, using an init, not using it, trying all sorts of stuff. D:

Okay, so wait. i saw that you wrote

Code: Select all

show "popup.png" with moveinbottom
write this instead

Code: Select all

show popup with moveinbottom
hide popup with moveinbottom
you dont need to write "popup.png" because it was already defined.
I am a friendly user, please respect and have a good day.


Image

Image


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

Re: Expected 'image_name_component' not found -error?

#5 Post by chesarty »

isobellesophia wrote: Sun Aug 18, 2019 12:20 am
chesarty wrote: Sat Aug 17, 2019 11:22 pm
isobellesophia wrote: Sat Aug 17, 2019 9:46 pm Can you show how do you define the image?
I define it with a simple

Code: Select all

image popup="game/images/popup.png"
I've also tried various other ways to define it, using an init, not using it, trying all sorts of stuff. D:

Okay, so wait. i saw that you wrote

Code: Select all

show "popup.png" with moveinbottom
write this instead

Code: Select all

show popup with moveinbottom
hide popup with moveinbottom
you dont need to write "popup.png" because it was already defined.
I tried both ways, neither way worked. :/

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: Expected 'image_name_component' not found -error?

#6 Post by Remix »

If the image (popup.png) is in ./images or any sub-folder in there it will be automatically defined as popup

so remove the 'image popup = "...' bit (you do not need that and it should Not have "game/ in it anyway) and just do

show popup with moveinbottom
Frameworks & Scriptlets:

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

Re: Expected 'image_name_component' not found -error?

#7 Post by chesarty »

Remix wrote: Sun Aug 18, 2019 7:13 am If the image (popup.png) is in ./images or any sub-folder in there it will be automatically defined as popup

so remove the 'image popup = "...' bit (you do not need that and it should Not have "game/ in it anyway) and just do

show popup with moveinbottom
Y'all aren't listening to me. I tried it both ways multiple times and it does not show up.

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: Expected 'image_name_component' not found -error?

#8 Post by Remix »

Show the code you are using...
Tell us exactly what the image is named and which folder it is in...
Do you define the image or not?
What version of Ren'Py are you using?
Frameworks & Scriptlets:

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

Re: Expected 'image_name_component' not found -error?

#9 Post by chesarty »

Remix wrote: Sun Aug 18, 2019 11:36 am Show the code you are using...
Tell us exactly what the image is named and which folder it is in...
Do you define the image or not?
What version of Ren'Py are you using?
Somehow I got it working after trying the exact same thing I tried previously? Maybe Ren'Py was just glitching out the other day :/ Frustrating, but I'm glad to have it working now.
I used this tutorial for it: viewtopic.php?t=35373
Now my issue is that the popup is at the very bottom of the page. Is there a way to align the position properly with xpos and so on?

Post Reply

Who is online

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