This profile is from a federated server and may be incomplete. Browse more on the original instance.
crei0, 9 months ago to godot in Godot 4 Help Understanding Signals @plixel @Rodeo The way I'm doing in my game is by Using a Signals.gd script Add that script to Project settings > Autoload, this makes the script globally accessible (singleton) Then from the scene I want to send the signal, I do Signals.my_signal_was_triggered.emit(<optional variables here>) Then on the scene/node (can by multiple) I want to receive the signal emission, I do Signals.my_signal_was_triggered.connect(my_function) Create the function "my_function"
@plixel @Rodeo The way I'm doing in my game is by
Using a Signals.gd script
Add that script to Project settings > Autoload, this makes the script globally accessible (singleton)
Then from the scene I want to send the signal, I do Signals.my_signal_was_triggered.emit(<optional variables here>)
Then on the scene/node (can by multiple) I want to receive the signal emission, I do Signals.my_signal_was_triggered.connect(my_function)
Create the function "my_function"