added flag to set anatimg