Create a new scene (Ctrl+N) with Area2D as root
VisibleOnScreenNotifier2D
Select the CollisionShape2D
Set the Shape to New CircleShape2D
Attach a new script to it
Add an export variable for the spell speed
Create a function called on area entered
To destroy Goblins when Spells
Create the ready function
Destroy spells when outside the visible screen area
Connect the area entered signal to the function we made
Create the process function
To move the spell constantly
Spells are spawned by the Wizard - return to the Wizard scene
Add a Marker2D as a child
Rename it to SpellSpawnPoint
Place it at the Wizard's staff
Add an export variable to
To create a spell from the scene
Rotate it to match the marker
Map an action to the shoot command
Project => Project Settings => Input Map
Add an action called shoot
Map the left mouse click to it
And call the shoot function