Posted May 17, 2023 by will2781
This is the animations script.
The movement animation runs whilst movement is detected. If movement isn't detected then the idle animation plays.
This code is run in the update method.
The attack animation stops you from moving whilst it plays.
It checks that whilst its playing you cant move, then when it ends you can move again.