Skip to content

Commit

Permalink
add clarifying comments on what the override does and why
Browse files Browse the repository at this point in the history
  • Loading branch information
ThePotatoGuy committed Feb 25, 2024
1 parent a04fc92 commit 27dd257
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions Monika After Story/game/overrides.rpy
Original file line number Diff line number Diff line change
Expand Up @@ -79,9 +79,16 @@ python early in mas_overrides:
This specific function is called before the init scripts start running
so this is the last place we can remove the scripts rpa stuff we dont
want.
renpy.game.script.initcode contains a list of AST nodes that will be
loaded on init - script-poemgame is the only known init that crashes
startup, so any AST node coming from that file is removed from
initcode here.
"""
global report_parse_errors_ran

# report_parse_errors runs multiple times (counted 10 on startup)
# so this is guarded to only run once
if not report_parse_errors_ran:
for index, initcode in reversed(list(enumerate(renpy.game.script.initcode))):
init_lvl, obj = initcode
Expand Down

0 comments on commit 27dd257

Please sign in to comment.