bit of a tidy up of ball.py