minor refactoring of game.rb