Simple billiard game implemented with HTML5