Closed jackmcbarn closed 9 years ago
This is a tricky one.
the with with the paired attribute is only emitted by the ren'py parser on a with statement concatenated to another statement, e.g.:
scene bg house with dissolve
This is compiled to
<renpy.ast.With
.expr = u'None',
.next = None,
.paired = u'dissolve2'
>,
<renpy.ast.Show
irrelevant stuff snipped
>,
<renpy.ast.With
.expr = u'dissolve2',
.next = None,
.paired = None
>
since
scene bg house with dissolve
is equal to
with None
scene bg house
with dissolve
And now the silly thing is, internally the engine does nothing with the paired attribute. Except that it's passed to renpy.config.with_callback, which by default also does nothing with it, but it could've been changed by the user so it might trigger a different result in that case.
It should be relatively easy to fix though.
It should be fixed now, if it encounters a with-statement-with situation in the ast node list it will reconstruct the postfix with statements properly.
Thanks for the issue reports, I really appreciate it.
Given this original dump:
If the rpyc that gave that dump is decompiled and then recompiled, here's the new dump:
Every .paired inside a With has been changed to None.