OnTriggerEnter not firing for objects with the same tag,How to detect multiple instances of the same tag using OnCollisionEnter

Hi all.
I’m working on a game where you push a bunch of spheres inside a hole.
Each sphere is an instance of a prefab and they all have the same tag and the same script below.

I’m trying to use OnCollisionEnter to detect when each of the balls touch the hole and increment count, but I only get the event called once, twice maximum, even though I have dozens of balls colliding with the hole, and the count is not incremented as it should, hence never entering the if.

Is there a way make sure I capture each of the collisions from each of the balls?

private void OnTriggerEnter(Collider other)
    {
        Debug.Log("Ball hit: " + other.gameObject.tag);
        if (other.gameObject.tag == "Hole")
        {
            count++;
            Debug.Log("count: " + count);
            if (count > 5)
            {
                DoSomethingHere();
            }
        }
    }

Appreciate your help!

see if this works?

`

[Header("OnTrigger Control:")]
[Space]

[Tooltip ("What is the Tag on the Objects we want to find in the scene?")]
[TextArea(1)]
[SerializeField]
private string Tag="Hole";

[Space]

[Tooltip ("If we are using as a trigger, is it a trigger enter or trigger exit?")]
public bool IsTriggerExit=false;

private void OnTriggerEnter(Collider other)
{
   if(GameObject.FindObjectsWithTag(Tag).Contains(other.gameObject)){
         count++;
         Debug.Log("count: " + count);
         if (count > 5)
         {
             if(Equals (IsTriggerExit,false)){
                   Debug.Log(string.Format("We made it to {0} with: ", count ) + other.gameObject.name)+"(Enter)");
             }
             DoSomethingHere();
         }
     }
 }

private void OnTriggerExit(Collider other)
{
   if(GameObject.FindObjectsWithTag(Tag).Contains(other.gameObject)){
         Debug.Log("count: " + count);
         if (count > 5)
         {
             if(Equals (IsTriggerExit,false)){
                   Debug.Log(string.Format("We made it to {0} with: ", count ) + other.gameObject.name+"(Exit)");
             }
             DoSomethingHere();
         }
     }
 }

`

I got it!!! Such a beginner’s mistake…

The count variable was being created inside each of the ball objects, hence it was never incremented as each object had it’s own counter.

I created a counter inside a different class and started incrementing it from each of the balls.

BOOM!

Thank you!