Animation optimization; bug fixes