I am creating a tower defense where the enemies run through certain areas to give them power ups. I have the enemies navigating to and running through the trigger areas. The trigger has a collider, and is checked for “is trigger” on that collider. I have setup multiple triggers for audio and player pickups before and haven’t encountered any problems.
I thought the issue might have been that my enemies are sitting within an empty gameObject to fix their rotation while pathing, but I added a collider to that ‘shell’ gameObject and tagged it as Enemy as well to see if it would hit the trigger, and still no luck. Below is my trigger code and all the enemies I’m instantiating are tagged as Enemy.
function OnTriggerEnter (col : Collider){
if(col.gameObject.tag == "Enemy"){
Debug.Log("Stone Trigger Hit");
}
}
I’m just keeping the code as simple as possible until I can actually see that it is triggering.