I'm just having fun with p5 while learning about Machine Learning. Use and modify the code as you want, just keep in mind everything is probably wrong as I have no idea what I am doing.
If you really want to learn about Processing & p5 (visualisation, making games, ...) or the concepts behind Machine Learning, I kindly recommend you to follow Daniel Shiffman instead. You can grab the assets I've used from here.
I've did this Flappy Bird clone about a year ago and adapted the code to implement a Perceptron, poor's man Genetics and any new crazy thing I've watched on Shiffman's YouTube channel.
I've also took the idea about the distance to the tubes and elevation from this video.
Please feel free to open issues and pull requests.