Last two game.js functions