Added a method in gravity to get the new velocity