melee animation keeps looping

hello, I have a basic knowledge of C#, and im making a FPS game. I have my attack animation that is attached to a boolean, and when I set the boolean to true, it just keeps looping. I tried doing: anim.SetBool(“Attack”, true); and then immidiately after setting it o false, but then the animation doesn’t play at all. I also tried unchecking loop time, and has exit time, but it still doesn’t work. please help:)

Hi MaltheTheFirst ,

I’m very new to unity and c# but please explain a bit more because most of us would not see the context … for exampe “animation that is attached to a boolean” … for my uderstanding would be : if player press some action (e.g left mouse button) than set ‘animation’ true when it is finish false etc.