init 999 python: import re Replay.locked = property(lambda _: False, lambda *_: None) PATTERN = re.compile(".+(:?ch|_)\d+") class PersistentPatch: def __getattr__(self, name): if PATTERN.match(name) is not None: return True return getattr(persistent, name) patched_persistent = PersistentPatch() class PatchedContext(renpy.sl2.slast.SLContext): def __init__(self, *args, **kwargs): super(PatchedContext, self).__init__(*args, **kwargs) screen_name = renpy.display.screen.current_screen().screen_name[0] if screen_name == "gallery": self.scope["persistent"] = patched_persistent renpy.sl2.slast.SLContext = PatchedContext