updated animation structure to avoid crash on iOS 6