updated file to contain the rest of the functions for animation