HTML5 implementation of the game