extends Area2D

var _parent : EnemyBase

signal avoid

func _ready() -> void:
	_parent = get_parent().get_parent()
	avoid.connect(_parent.avoid_enemy)

func _on_body_shape_entered(_body_rid: RID, body: Node2D, _body_shape_index: int, _local_shape_index: int) -> void:
	if body != _parent and body is EnemyBase:
		avoid.emit()
