How do you detect which collider is triggered when you have multiple?

I have an enemy gameobject with 3 colliders attached to it, one is a trigger to tell it when something is in it’s “sight” to target other enemies, there is another trigger to detect when something is hit by it’s attacks, and a third that is not a trigger to detect when it gets hit by attacks. The problem is that I cant find a way to tell which of the two trigger colliders is being triggered with the OnTriggerEnter() method. I need it to do separate things when the sensor trigger is hit than when something is in it’s attack range. I have all of the colliders in my code as variables so I can differentiate between them but I can’t find a variable for the collider that calls the OnTriggerEnter() method. Here is the code for my enemy class:

public int health, damage;
    //Linger = time the attack stays active, Delay = for the player to dodge attacks before they activate
	public float linger, delay, range, attackRange, speed;
    //Accumulation of time between updates to tell how ling it's been since an attack started
	private float timePassed;
	private Transform target;
	private bool attacking = false;
    //Two trigger colliders sensor is used to aquire a target, attackCol is used to deliver attacks
	public SphereCollider sensor, attackCol;

	public void Start()
	{
		attackCol.enabled = false;
		sensor.radius = range;
		attackCol.radius = attackRange;
	}
    
    public void Update()
    {
		if (attacking) 
		{
			timePassed += Time.deltaTime;
		}

		if (timePassed >= delay) 
		{
			attack ();
		}

		if (timePassed >= linger + delay) 
		{
			attacking = false;
			attackCol.enabled = false;
			timePassed = 0;
		}

		if (target != null && !attacking) 
		{
			attackTarget(target, Time.deltaTime);
		}
    }

	public void attackTarget(Transform t, float deltaTime)
	{
        //Checks if the target is in attack range
		float distance = Mathf.Sqrt (Mathf.Pow (t.position.x - transform.position.x, 2) + Mathf.Pow (t.position.y - transform.position.y, 2));
		if (distance > attackRange / 2) {
			attack ();
            attacking = true;
		} else {
            //Faces and moves toward the target
			transform.rotation = Quaternion.Euler(0, getAngle(transform.position, t.position) * (180/ Mathf.PI), 0);
			transform.position += new Vector3(Mathf.Cos(getAngle(transform.position, t.position)), 0, Mathf.Sin(getAngle(transform.position, t.position))) * speed * deltaTime;
		}
	}

    public void attack()
    {
		attackCol.enabled = true;
    }

    public void OnTriggerEnter(Collider other)
    {
        if(other.gameObject.GetComponent<Player>() != null)
        {
			target = other.transform;
        }
    }

The colliders are set in the inspector and although you cant tell the difference by name I made sure they are not the same collider listed twice
83684-capture.png

And both colliders show up in the editor when the game is run

83685-capture2.png

However the script cannot tell the difference between the two trigger colliders

Place two child gameObjects with different tag names after that you will identify which collider its triggered

public void OnTriggerEnter(Collider other)
{
if(other.gameObject.GetComponent() != null)
{
if (other.collider == other.gameObject.GetComponent().attackCol)
target = other.transform;
}
}