I don’t know where I am going wrong, but am inexperienced with using the Animator. I do not understand why my trigger of “InRange” is not working, when the code I am using is based on working code in the Survival Shooter Tutorial and the appropriate API.
void OnCollisionEnter(Collision col)
{
if (col.gameObject.CompareTag("Player"))
{
animator.SetTrigger("InRange");
}
}
My Player has the tag of Player, the following object has the trigger collider. When the following asset enters the collider, it carries on doing its original animation.
Any help on where I’m going wrong would be appreciated.
