adding rails to html5 game