From 5c4106246c29538357ee1816e123246036a64a92 Mon Sep 17 00:00:00 2001 From: Chris Cromer Date: Sat, 23 Jul 2022 13:27:21 -0400 Subject: [PATCH] fix error that happens after the GUI is freed --- godot/monitor/Monitor.gd | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/godot/monitor/Monitor.gd b/godot/monitor/Monitor.gd index 0c96cc7..e146477 100644 --- a/godot/monitor/Monitor.gd +++ b/godot/monitor/Monitor.gd @@ -99,8 +99,9 @@ func _ready() -> void: func _physics_process(_delta: float) -> void: if monitor_enabled: - if not $MonitorGUI.visible: + if has_node("MonitorGUI") and not $MonitorGUI.visible: $MonitorGUI.visible = true + if started and not get_tree().paused: var frame = empty_frame.duplicate(true) frame["coins"] = coins -- 2.30.2