perfectioned ainimate line draw function