When you click the mouse, touch the screen, or press a key the bird is given some upward velocity.
We know how to make things fall and bounce convincingly, but Flappy Bird doesn't do accurate simulation of physics.
Instead, the bird is only affected by gravity until it reaches a maximum fall-speed, then stays falling at that speed.
We're going to set up a few variables to help control how this will work:
|
|