Moved game logic to method

Allows for recursion, or running itself