Html 5 game built with pure JS