Add gravity
Let’s add gravity to the bird:
Add below command in the file [File: create-game.js] bird.body.gravity.y = 900;
Working Together
In the repl.it window below, we started the code with the line bird.body.gravity.y = 900;
.
In your console you should see a JSappy bird jumping with gravity after you press run: