forked from SilverStudioGames/WTS
Remove now-unused reset_variables relying on implem details
It is used in a txt draft which I didn't change, it can be done if deemed necessary I think this function should be kept off, as it is both more dangerous and slower than the workarounds
This commit is contained in:
parent
757a39d782
commit
9b96c5572c
@ -101,20 +101,6 @@ init python early:
|
|||||||
print("Error evaluating data:")
|
print("Error evaluating data:")
|
||||||
print(e)
|
print(e)
|
||||||
|
|
||||||
def reset_variables(*args):
|
|
||||||
"""Resets the given variables to their default values."""
|
|
||||||
# Refer to renpy.ast.Default.set_default for implementation details
|
|
||||||
defaults_set = renpy.store._defaults_set
|
|
||||||
changed_set = renpy.store.__dict__.ever_been_changed
|
|
||||||
for arg in args:
|
|
||||||
if arg in defaults_set:
|
|
||||||
if arg in changed_set:
|
|
||||||
defaults_set.remove(arg)
|
|
||||||
changed_set.remove(arg)
|
|
||||||
elif config.developer:
|
|
||||||
raise Exception("The variable `{}` was not previously set with a default value.".format(arg))
|
|
||||||
renpy.execute_default_statement(False)
|
|
||||||
|
|
||||||
def disable_game_menu():
|
def disable_game_menu():
|
||||||
setattr(renpy.store, "_game_menu_screen", None)
|
setattr(renpy.store, "_game_menu_screen", None)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user