I'm new to gdscript trying make 2D platformer game in godot3,I'm able to instance a fire scene when the Player node enters the area2D which is im using as field of vision but the scene only instantiate once.How do we keep instancing the fire scene till the player is within the field of vision (Area2D)?
My GDscript :
#monster.gd
func _on_field_of_detection_body_entered(body):#signal passed from Area2D
if body.name == "Player": # When field of detection detect the player it load the fire.tscn scene.
var fir = fire.instance()
fir.set_global_position($fireposition.get_global_position())
get_parent().add_child(fir)