How to get name of signal emitter

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

I have 15 buttons in my game and I have connected there pressed() signal to the root to this function.

func delete_me():
    #Delete the button which had emitted that signal

Can anyone tell how to delete(or any other things) the node which has emitted the signal

:bust_in_silhouette: Reply From: Wakatta

Pass a reference of the object to the function as a parameter.


connect("pressed", node_with_delete_me_function, "delete_me", [self])


func delete_me(button):
    #Deletes the button which emitted the signal