extends ObstacleSpawner

@export var spawners: Array[Marker2D] = []
@export var oncoming: bool = false


func spawn_obstacle() -> void:
	var spawned := obstacles[randi() % obstacles.size()].instantiate() as EnemyCar
	var rnd_spawner: Marker2D = spawners[randi() % spawners.size()]
	rnd_spawner.add_child(spawned)
	spawned.flip = oncoming
