I have the same code for both projectiles but only one works. When in game i type the spell name and send it in but only one appears while the other doesn't even appear. Code: bullet: fireball the one that works icebolt: copy but doesnt work gun: signal receiver for the spells SpellBox: where i type spells in and send signal out if it matches.
I don’t see where the signals (fireball, icebolt) are connected. Show that code. The most probable reason for the problem is that you just don’t connect the icebolt signal to _on_spell_box_icebox function.
If a signal is connected to a function (via the editor), it shows the green icon in front of it, like for _on_body_entered() in the first screenshot. Neither _on_spell_box_fireball() nor _on_spell_box_icebolt() show this icon, meaning they are not connected.
If you change the name of a function, you have to reconnect the signal, because with a new name it is considered a new function.
they are connected but the green icon doesn’t appear because i wasn’t on the selected node if i select the bullet node the green icon appears and vise versa for icebolt
The tutorial doesn’t seem to use custom signals for this? It connects a Timer’s timeout signal to a function, and from there calls a shoot() function.
Also, just because your fireball signal is connected doesn’t mean your icebolt signal is as well. Are you getting the “signal received” and “end” prints?
Copy the content of _on_spellbox_fireball to the _on_spellbox_icebolt and test. If “icebolt” now works shooting fireballs, then the problem is probably in the icebolt scene.