Side image doesn't use default image during dialogue

In this forum we discuss the future of Ren'Py, both bug fixes and longer-term development. Pre-releases are announced and discussed here.
Post Reply
Message
Author
obi_dev
Newbie
Posts: 7
Joined: Wed Aug 16, 2017 9:12 pm
Contact:

Side image doesn't use default image during dialogue

#1 Post by obi_dev »

Simple problem, but not sure about simple solution..

Code: Select all

image side mom = Image("images/portraits/mom.png", xoffset=-50, yoffset=130)
image side mom sad = Image("images/portraits/mom-sad.png", xoffset=-50, yoffset=130)

Code: Select all

mom "stuff stuff"
mom sad "stuff stuff"
mom "stuff stuff"

During dialogue, the default mom.png shows, then sad kicks in and mom-sad.png shows, but when I go back to 'mom', mom-sad.png is still showing.

If i did the example below, it resets it, but I don't want to have to do that everytime :\ unless i have to. when 'mom xx' comes up, the default image shows.

Code: Select all

mom "stuff stuff"
mom sad "stuff stuff"
mom xx "stuff stuff"
mom "stuff"

User avatar
PyTom
Ren'Py Creator
Posts: 16088
Joined: Mon Feb 02, 2004 10:58 am
Completed: Moonlight Walks
Projects: Ren'Py
IRC Nick: renpytom
Github: renpytom
itch: renpytom
Location: Kings Park, NY
Contact:

Re: Side image doesn't use default image during dialogue

#2 Post by PyTom »

This is correct behavior, it's tracking the character attributes.
Supporting creators since 2004
(When was the last time you backed up your game?)
"Do good work." - Virgil Ivan "Gus" Grissom
Software > Drama • https://www.patreon.com/renpytom

obi_dev
Newbie
Posts: 7
Joined: Wed Aug 16, 2017 9:12 pm
Contact:

Re: Side image doesn't use default image during dialogue

#3 Post by obi_dev »

PyTom wrote: Sat Aug 19, 2017 7:05 pm This is correct behavior, it's tracking the character attributes.
So, your pretty much saying then that to get it to reset, i'd have to do

mom
mom sad
mom xx

Where XX would revert back to default. Interesting, but no worries. I figured I could make a "mom r" for reset and assign same attributes as mom.
Thanks for the help :D

User avatar
PyTom
Ren'Py Creator
Posts: 16088
Joined: Mon Feb 02, 2004 10:58 am
Completed: Moonlight Walks
Projects: Ren'Py
IRC Nick: renpytom
Github: renpytom
itch: renpytom
Location: Kings Park, NY
Contact:

Re: Side image doesn't use default image during dialogue

#4 Post by PyTom »

Actually, xx is sort of a problem. (I'm surprised it works.) The right way to do it is.

Code: Select all

mom -sad "I'm not sad anymore."
Supporting creators since 2004
(When was the last time you backed up your game?)
"Do good work." - Virgil Ivan "Gus" Grissom
Software > Drama • https://www.patreon.com/renpytom

obi_dev
Newbie
Posts: 7
Joined: Wed Aug 16, 2017 9:12 pm
Contact:

Re: Side image doesn't use default image during dialogue

#5 Post by obi_dev »

PyTom wrote: Sat Aug 19, 2017 9:03 pm Actually, xx is sort of a problem. (I'm surprised it works.) The right way to do it is.

Code: Select all

mom -sad "I'm not sad anymore."
Yeah, I noticed when I did mom xx, it worked, but when I did the lint check, it came back with an undefined warning.
However, with -sad, I get an error

Code: Select all

I'm sorry, but an uncaught exception occurred.

While running game code:
NameError: name 'sad' is not defined

User avatar
PyTom
Ren'Py Creator
Posts: 16088
Joined: Mon Feb 02, 2004 10:58 am
Completed: Moonlight Walks
Projects: Ren'Py
IRC Nick: renpytom
Github: renpytom
itch: renpytom
Location: Kings Park, NY
Contact:

Re: Side image doesn't use default image during dialogue

#6 Post by PyTom »

I need to look into this. It's possibly a problem parsing the say statement.
Supporting creators since 2004
(When was the last time you backed up your game?)
"Do good work." - Virgil Ivan "Gus" Grissom
Software > Drama • https://www.patreon.com/renpytom

Post Reply

Who is online

Users browsing this forum: No registered users