about connect() in godot

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By shotaku

Is my understanding of the connect() function like this , correct everyone?
$Timer.connect(“timeout”, self, “func_example”)
The connect() function will execute the func_example method when a signal in Timer is emitted, its true?

:bust_in_silhouette: Reply From: beebanoo

When the timer node emits the specific “timeout” signal, the node passed as the second parameter (in your case - self) will execute the function with the same name as the third parameter (in your case - funcexample)

Make sure the timer node is either set to autostart or you manually start it if you ever want the timeout signal to be emitted.