Example #1
0
    def print_screen(self, ast):
        screen = ast.screen
        if isinstance(screen, renpy.screenlang.ScreenLangScreen):
            screendecompiler.pprint(self.out_file, screen, self.indent_level,
                                    self.force_multiline_kwargs, self.decompile_python,
                                    self.decompile_screencode)

        elif isinstance(screen, renpy.sl2.slast.SLScreen):
            sl2decompiler.pprint(self.out_file, screen, self.indent_level,
                                 self.force_multiline_kwargs, self.decompile_screencode)
        else:
            self.print_unknown(screen)
Example #2
0
    def print_screen(self, ast):
        self.require_init()
        screen = ast.screen
        if isinstance(screen, renpy.screenlang.ScreenLangScreen):
            self.linenumber = screendecompiler.pprint(self.out_file, screen, self.indent_level,
                                    self.linenumber,
                                    self.decompile_python,
                                    self.skip_indent_until_write,
                                    self.printlock)
            self.skip_indent_until_write = False

        elif isinstance(screen, renpy.sl2.slast.SLScreen):
            def print_atl_callback(linenumber, indent_level, atl):
                old_linenumber = self.linenumber
                self.linenumber = linenumber
                with self.increase_indent(indent_level - self.indent_level):
                    self.print_atl(atl)
                new_linenumber = self.linenumber
                self.linenumber = old_linenumber
                return new_linenumber

            self.linenumber = sl2decompiler.pprint(self.out_file, screen, print_atl_callback,
                                    self.indent_level,
                                    self.linenumber,
                                    self.skip_indent_until_write,
                                    self.printlock,
                                    self.tag_outside_block)
            self.skip_indent_until_write = False
        else:
            self.print_unknown(screen)
Example #3
0
    def print_screen(self, ast):
        screen = ast.screen
        if isinstance(screen, renpy.screenlang.ScreenLangScreen):
            self.linenumber = screendecompiler.pprint(
                self.out_file,
                screen,
                self.indent_level,
                self.linenumber,
                self.decompile_python,
                self.match_line_numbers,
                self.skip_indent_until_write,
            )
            self.skip_indent_until_write = False

        elif isinstance(screen, renpy.sl2.slast.SLScreen):
            self.linenumber = sl2decompiler.pprint(
                self.out_file,
                screen,
                self.indent_level,
                self.linenumber,
                self.match_line_numbers,
                self.skip_indent_until_write,
            )
            self.skip_indent_until_write = False
        else:
            self.print_unknown(screen)
Example #4
0
    def print_screen(self, ast):
        screen = ast.screen
        if isinstance(screen, renpy.screenlang.ScreenLangScreen):
            self.linenumber = screendecompiler.pprint(
                self.out_file, screen, self.indent_level, self.linenumber,
                self.decompile_python, self.skip_indent_until_write)
            self.skip_indent_until_write = False

        elif isinstance(screen, renpy.sl2.slast.SLScreen):
            self.linenumber = sl2decompiler.pprint(
                self.out_file, screen, self.indent_level, self.linenumber,
                self.skip_indent_until_write)
            self.skip_indent_until_write = False
        else:
            self.print_unknown(screen)