Problem with the "animator.SetTrigger("Attack");"

I can’t get my “animator.SetTrigger(“Attack”);” line to work. I’ve triple checked all the animation videos but I don’t know whats wrong.

Link to the video
^In this video you can see that my animation (clicked from the animator) is working, but when I attack enemy, it bugs out.
Also, I’ve commented the “animator.SetTrigger(“Attack”);” out, and it works just fine (but without the animation).

1 Like

I hate to gravedig, but have you checked you’re assigning the animator to an object?

e.g. animator = GetComponent();

Hi, I’m so sorry to late reply. Forgot to check this site!

I found the problem and it was some stupid typo somewhere else. I don’t even remember anymore, lol. Thanks anyways :smiley:

Privacy & Terms