added animation routine that is now in a settimeout