I have a peculiar bug I've been trying to figure out. Every time a sprite of one particular character appears in my game, he breaks the background image and causes it to not display. I have no clue why this is. He's a .png just like all my other sprites, so I have no idea why it does this.
I've narrowed down the issue as probably something to do with the image file itself, as when any version if his sprite appears, it breaks, but when I comment it out it's fine. I've attached screenshots of the issue with the sprite(s) in question, and when I comment it out and the background works.
Any ideas as to what might be going on or how to fix this?
Sprite breaking background image?
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.
Re: Sprite breaking background image?
What's the name of the sprite or the part of code that declares sprites and bg? What's the part of the code that shows all that sprites and bg? What line can be commented to not make bg image disappear?
-
- Newbie
- Posts: 3
- Joined: Sun Nov 14, 2021 4:26 pm
- Deviantart: sakohju
- Github: sakohju
- itch: sakohju
- Contact:
Re: Sprite breaking background image?
I've attached screenshots of the code below - the character declarations, and the line in particular from the screenshots I included above. It's the line where I show the noodle man's sprite, I've included screenshots of the line in question commented out and displaying a different sprite for the same character but different expression (like above). It doesn't just happen in this one spot, it's any time I'm showing a noodle man sprite, it breaks the background.
Re: Sprite breaking background image?
You've named bg image as 'noodle shop' and sprite as 'noodle sleazy'. Both have the same tag 'noodle', so they replace each other.
Try to rename all your bg images like 'bg noodle shop', so they will have 'bg' tag.
https://www.renpy.org/doc/html/displayi ... l#concepts
-
- Newbie
- Posts: 3
- Joined: Sun Nov 14, 2021 4:26 pm
- Deviantart: sakohju
- Github: sakohju
- itch: sakohju
- Contact:
Re: Sprite breaking background image?
That fixed it! Thank you so much!
Who is online
Users browsing this forum: Google [Bot]