Created game as a function