I'll be real. I've never worked with coding or anything even remotely close to the Ren'Py system. (Except for Mugen almost a decade ago.) In this regard, I thought I thoroughly looked over at least the basics for inserting images, music, and dialogue for Ren'Py.
I even looked through the scripts for both 'The Question' and the 'Tutorial'. So following probably the most basic instructions for the game, I attempted to insert my own test pictures, dialogue, and music into a new project.
The character sprite works, the music works, and dialogue works. However, the two background pictures I used are being shown as black screens with the 'Undefined Image' message at the top of the screen.
After a frustrating hour of having no clue what to do, I attempted to add one of the images into the script for 'The Question' and it worked with no problem. So now, I'm stuck and highly annoyed. I really hope someone can help me out with this one.
Getting Undefined Image code for Backgrounds (Solved)
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.
- KusanagiKyo
- Newbie
- Posts: 7
- Joined: Sun Jan 26, 2014 12:26 am
- Projects: Edgy (Non-commercial, flag type dating)
- Contact:
Getting Undefined Image code for Backgrounds (Solved)
Last edited by KusanagiKyo on Sun Jan 26, 2014 1:20 am, edited 1 time in total.
Re: Getting Undefined Image code for Backgrounds
sure, please post your code so we can help.
- KusanagiKyo
- Newbie
- Posts: 7
- Joined: Sun Jan 26, 2014 12:26 am
- Projects: Edgy (Non-commercial, flag type dating)
- Contact:
Re: Getting Undefined Image code for Backgrounds
I go into dialogue and such after that.# Declare images used by this game.
image bg Room 1 = "CleanroomDay.jpg"
image bg Room 2 = "CleanroomEvening.jpg"
image bg Room 3 = "CleanroomNight.jpg"
image bg Room 4 = "ClearnroomDark.jpg"
image Rinahappy = "Rinahappy.png"
image Rinadismay = "Rinadismay.png"
image Rinaangry = "Rinaangry.png"
image Rinasurprised = "Rinasurprised.png"
image Rinasweatdrop = "Rinasweatdrop.png"
image Rinaupset = "Rinaupset.png"
# Declare characters used by this game.
define r = Character('Rina', color="#c8ffc8")
define j = Character('Jin', color="#c8ffc8")
# The game starts here.
label start:
scene Room 4
with fade
I know that Room 4 is misspelled. I thought that was the problem at first, but when I corrected it, it didn't change anything. Also, I changed the room titles from 'CleanroomDay' and such to 'Room 1' etc, in hopes of fixing the problem as well.
Re: Getting Undefined Image code for Backgrounds
and you're not getting an error, just undefined where the bg should be... is the file in your /game directory with your sprites? do you have the name and extension correct?
Re: Getting Undefined Image code for Backgrounds
oh, try "scene bg Room 4" instead if just "Room 4".
you defined by as part of the name.
you defined by as part of the name.
- KusanagiKyo
- Newbie
- Posts: 7
- Joined: Sun Jan 26, 2014 12:26 am
- Projects: Edgy (Non-commercial, flag type dating)
- Contact:
Re: Getting Undefined Image code for Backgrounds
...
I knew it.
I just knew it was going to be some simple thing to solve and I was just being so impatient that I was constantly overlooking it...
Thank you sooo much Unin, you have no idea how much you've just made my day. XD
P.S, It's working perfectly. Now to create the most epic games ever! (Insert evil laugh)
I knew it.
I just knew it was going to be some simple thing to solve and I was just being so impatient that I was constantly overlooking it...
Thank you sooo much Unin, you have no idea how much you've just made my day. XD
P.S, It's working perfectly. Now to create the most epic games ever! (Insert evil laugh)
Re: Getting Undefined Image code for Backgrounds (Solved)
no prob. bug checking code is a lot like proof-reading a paper; sometimes your eyes get use to your own style, and your brain glosses over mistakes by showing what you meant, instead if what's really there; things that fresh eyes notice right away.
Who is online
Users browsing this forum: Andredron, Google [Bot]