Adding gravity to sprites in canvas

This is from

Notice how the X and Y are changed separately, under different influences.