made changes in how the applyGravity method works. now makes use of the Gravity.getNewYPosition
method