handle marker animation better and stop leaking memory