moved checking if click triggered other animations to separate function