fix: allows for proper reloading of all globals (reserved or otherwise); also now properly saves reserved objects; plus a couple small guards to correct issues while quitting after loading games in certain conditions

This commit is contained in:
Duncan Brown
2022-03-23 18:10:09 -04:00
committed by Julian Murgia
parent 84c84d3a0f
commit 7ff0176d62
5 changed files with 42 additions and 15 deletions

View File

@@ -226,7 +226,11 @@ func set_game_paused(p_paused: bool):
emit_signal("paused")
else:
emit_signal("resumed")
get_tree().paused = p_paused
var scene_tree = get_tree()
if is_instance_valid(scene_tree):
scene_tree.paused = p_paused
# Runs the event "event_name" from the "script" ESC script.