You may need to use this as reference and put the play animation code inside the function with a cooldown.