Fixed small bug causing gravity to be zero