Mob spawning on wrong scene again

Godot 4

I’ve fixed this bug before but it’s happening again, last time it was an issue with the timers being named the same as one another but now this isn’t the case. For some reason when I instance the first fight scene it also runs the second scene causing enemies to spawn on the first scene.

code for first scene:

extends Node
@export var mob_scene: PackedScene
func _ready():
$Area2D.start($Marker2D.position)
$Timer2.start()

randomize()

func _process(delta):
pass

func _on_timer_2_timeout():
$Timer4.start()
$Timer3.start()

func _on_timer_4_timeout():
var mob = mob_scene.instantiate()
var mob_spawn_location = $Path2D/PathFollow2D
var direction = mob_spawn_location.rotation + PI /2
mob.position = mob_spawn_location.position
direction += randf_range(-PI / 4, PI / 4)
mob.rotation = direction
var velocity = Vector2(randf_range(150.0, 250.0), 0.0)
mob.linear_velocity = velocity.rotated(direction)
add_child(mob)

func _on_timer_3_timeout():
get_tree().change_scene_to_file(“res://mimicdefeated.tscn”)

code for second scene:

extends Node
@export var mob_scene2: PackedScene
func _ready():
randomize()
$Timer5.start()

func _on_timer_5_timeout():

var mob2 = mob_scene2.instantiate()
mob2.rotation = 0
mob2.position = Vector2(600, randf_range(-450 , 450))
var velocity2 = Vector2(randf_range(-150.0, -250.0), 0.0)
mob2.linear_velocity = velocity2.rotated(0)
add_child(mob2)