added logic to resolve game after players have played