extends ProgressBar func _ready() -> void: await get_tree().process_frame var crystals = get_tree().get_nodes_in_group("crystals") print("Got " + str(crystals.size()) + " crystals") for crystal in crystals: print("Connecting crystal: " + crystal.name) crystal.connect("crystal_picked_up", Callable(self, "collect")) func collect(): value += 2.0