Layered image weird behaviour (probably my fault)

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
Doogy
Newbie
Posts: 16
Joined: Wed Aug 19, 2009 9:52 am
Location: Rennes [France]
Contact:

Layered image weird behaviour (probably my fault)

#1 Post by Doogy »

Hi,
I got a weird thing happening...
I use a Picker function in a layered image to select attributes on the fly and I got some attributes even before the Picker function execute :/
This is my Picker function:

Code: Select all

    class Picker(object):
        def __init__(self, girl):
            self.girl =  girl
    
        def __call__(self, attr):
            renpy.log(str(attr))
            return attr
This is my layered image:

Code: Select all

layeredimage morgan:
        attribute_function Picker(morgan)
And when I do 'show morgan' this is the log I get:

Code: Select all

RevertableSet([u'casual', u'normal'])
Do you know what I could have done wrong ?
Sorry for my english, i am french.

Post Reply

Who is online

Users browsing this forum: No registered users