If you change the initial postion of the moving body (ro.x and ro.y) and the components of its velocity (vxi- and viy-) you will find out its displacement vector between two given moments.