'RevertableList' object is not callable

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
Shie
Regular
Posts: 41
Joined: Sun Apr 14, 2019 4:12 am
itch: shie
Discord: shie_3769
Contact:

'RevertableList' object is not callable

#1 Post by Shie »

It worked some time and than stopped working.
Here is code, please, tell me if i've done something wrong

Code: Select all

init python:
    class MyClass:
        def __init__(self,smf):
            self.smf = smf

    list = [MyClass(1)]
    a = 3

screen MyScreen(b):
    vbox:
        text "[a]"
        button action SetVariable("a", b.smf):
            text "click"
            
label start:
    call screen MyScreen (list[0])
"While running game code:
File "renpy/common/00library.rpy", line 247, in _predict_statements
rv = list(config.predict_start_labels)
TypeError: 'RevertableList' object is not callable"

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: 'RevertableList' object is not callable

#2 Post by Remix »

list is a reserved word in Python

suggest just change it to:

my_list = [ MyClass() ]

or somesuch
Frameworks & Scriptlets:

Shie
Regular
Posts: 41
Joined: Sun Apr 14, 2019 4:12 am
itch: shie
Discord: shie_3769
Contact:

Re: 'RevertableList' object is not callable

#3 Post by Shie »

Thanks! Such a silly mistake(

Post Reply

Who is online

Users browsing this forum: Google [Bot], MSN [Bot]