`How do you instance a scene. Like just make things re-spawn? I am reading docs but I’m not sure how to use it correctly. For example, if Y touches X how can I get the Y to respawn? I know I can use queue_free() to eliminate the node.
You can just create a function of respawn, where it will do its job, like maybe it will return to a specific position, etc. You can call this whenever need.
@export var enemy_scene: PackedScene
@onready var game = $ReferenceToYourMainGameScene
# drag and drop the scene you want to
# instantiate in the Inspector into the
# export variable above
var enemy = enemy_scene.instantiate()
# do things to this enemy instance like set position
game.add_child(enemy)
Roughly, the above would do what you want. Use that in conjunction with the video to get a better idea for your purposes.
Of course, this could be stored in a function, that gets called when a signal is emitted, say from a timer that spawns a new enemy every 5 seconds.