OnTriggerEnter not detecting tag?

Okay, so I’m trying to make an object do a function when it enters a trigger with the tag of “Trap” even thought they both have box colliders and the Trap tagged object’s box collider is set to ‘is trigger’. I’ve used print() to see if the trigger was working but it wasn’t triggered.

using UnityEngine;
using System.Collections;

public class Patrol : MonoBehaviour {
	public int NumberOfPoints;
	
	public GameObject enemydeathParticles;
	public Transform[] patrolPoints;
	public float moveSpeed;
	private int currentPoint;
	// Use this for initialization
	void Start () {
		transform.position = patrolPoints[0].position;
		currentPoint = 0;
	}
	
	// Update is called once per frame
	void Update () {
		if (transform.position == patrolPoints [currentPoint].position)
		{
			currentPoint++;
		}

		if (currentPoint == NumberOfPoints)
		{
			currentPoint = 0;
		 }


		transform.position = Vector3.MoveTowards (transform.position, patrolPoints [currentPoint].position, moveSpeed * Time.deltaTime);
	}

	
	void EnemyDie()
	{
		Instantiate(enemydeathParticles, transform.position, Quaternion.identity);
		print ("An Enemy has died!");
		Destroy(gameObject);
	}

	void OnTriggerEnter(Collider other)
	{
		if (other.transform.tag == "Trap")
		{
			EnemyDie ();
		}
	}
}

If you need anymore information, I’m here. Sorry if it’s just a stupid mistake :stuck_out_tongue:
Thanks for your time!

Try adding rigidbody in any one of the gameobject

Add Rigidbody components to both gameobject and set “Is Trigger” as True.

And have you got a (is kinematic) rigidbody attached to at least one of the objects?