added player physics, created pipe generation function